The lower branch merged master (release 0.2.2-rc.4) and made the forge
worktree blocker count the policy's additional writable roots.
- The new package's version follows the root, and the upgrade guide this
branch edits moved to `v0.2.2-rc.4` with the lower branch.
- With the worktree service mounted, a Session opened in a linked checkout
holds the grant, so the forge New worktree option is available there. The
forge panel tests expect no blocker once a Session works in its worktree,
and the source-repository policy of a restoration lists the repository's
Git directory before a registered grant; both keep the old expectation on
Windows, where the plugin registers nothing.
- The worktree and forge READMEs and the grant's Agent Note state that the
mounted grant covers the directory on macOS and Linux.
- Generated catalogs, graphs, pairing records, and the lockfile are taken
from the lower branch and regenerated.
A Session that works in a linked worktree could not run `git add` or
`git commit` under workspace-write: the worktree's index and the repository's
objects live in the repository's Git directory, outside the Session's
workspace root, and the sandbox policy reads no Git layout.
The new plugin `@deepseek-ai/dsh-sandbox-policy-git` registers that directory
through `ctx.sandboxPolicy.registerWritableRoot`. The worktree service depends
on it and mounts it; no bundle patch and no forge file changes.
- The layout is read at Agent creation and after `next()` in the
`working-directory/access` waterfall, which every Host move and the
validation before each model request pass through. Each read replaces the
Session's registration; Agent disposal and plugin unload remove it.
- A directory qualifies only when the Git directory names it as a worktree:
the `.git` file points at `<common>/worktrees/<name>`, whose `commondir`
resolves to `<common>` and whose `gitdir` resolves back to that `.git`
file, and `<common>` neither contains the directory nor lies inside it.
- The grant is the whole Git directory. The plugin registers nothing on
Windows, where process confinement ignores additional writable directories;
its suites are excluded there.
- A read failure grants nothing, warns once per Session and directory, and
never fails the directory operation.
The worktree sandbox tests that pinned the denial now pin the commit and the
creation from a linked checkout without a manual registration. Two worktree
tests that hooked the next `fs.lstat` call hook the service's own path check.
The recorded scenario `session/worktree-commit` pins the policy context the
model sees while it works in the worktree and after it leaves.
The sandbox policy derived a linked checkout's shared Git directory from its
`.git` pointer and granted it. That put Git worktree knowledge and a
worktree-only entry (`prepare`) into a generic service. The policy now bounds
a Session by its directory and adds only configured directories and those a
Host plugin registered through `registerWritableRoot`; relative to the lower
branch its source changes in one place, the root it reads.
- `prepare`, the derivation state, its three listeners, and
`src/linked-checkout.ts` are removed.
- The worktree service creates under the Session's policy as on the lower
branch; removal and restoration swap the root for the source checkout. The
forge panel's blocker reads the Session's root alone.
- A Session that works in a linked worktree cannot write the repository's Git
directory under workspace-write without a grant. Tests pin the denial and
that a registered grant admits creation, restoration, and a commit.
Granting the Git directory of the checkout a Session works in is left to a
separate plugin that reads the layout and registers the directory.
The lower branch merged master, which added a fetch of the remote base branch
to worktree creation. On this branch a Session opened in a linked checkout can
create worktrees, and the fetch writes the Git directory that checkout shares
outside its root. The fetch now runs under the policy resolved after
`prepare`, which grants that directory, as the later writes do. A real-sandbox
test fetches from a linked checkout.
The lower branch removed `rootOf` and the `workspaceRoot` projection: a Session
has one directory, read through `ctx.workingDirectory.get`. This merge moves the
consumers of this branch to that read.
- sandbox-policy, workspace-files, and workspace-changes read `get`; the
`recordedRootOf` read is removed. With the working-directory service mounted,
a Session without a header directory is bounded by that service's default
directory.
- The skill catalog, sidebar terminals, project instructions, `@` file
candidates, the LSP workspace, and skill lookup return to the lower branch's
code, which already reads the directory.
- The client helper exports `selectSessionDirectory` and `sessionDirectory`
in place of the `{ root, cwd }` pair; `WorkspaceChangesSummary` keeps `cwd`,
now the directory the turn started in.
- A stored `working-directory/change` inside the project moves the write
boundary and file views with the directory; one outside returns to the project.
master moved the `workingDirectory` projection-key declaration to
`src/types.ts`; this branch's `workspaceRoot` key follows it there. The three
recorded scenarios master added (`session-list-tools`,
`computer-use-cua-driver-mcp-ptc`, `sdk/subagent-dsh-sdk-empty-route`) drop the
removed `working_directory` tool and the delegation `cwd` parameter from their
sidecars.
The kind skills tell the model to end its answer with an `action-card`
fenced block. The card projection reads the first valid block of a turn
from the answer text and names the card by its assistant message id; it
still reads `propose_action` cards and `callId` decision records of older
Sessions. The Web plugin hides the block through the Chat Markdown fence
slot, and the card still appears below the answer.
Removes the `propose_action` tool, its skill-load tracking and the
`queuedMessageLimit` configuration, and renames card ids to `cardId`.
The graph still drew the web providers' edges to dsh-llm, the account
service, and the launch environment, which they dropped when they began to
ask ctx.deepseekAuth.
Both route plugins now require the DeepSeek authentication service and connect the deployment their settings name: the API-key route its base URL and key reference, the account route its base URL. Other DeepSeek consumers will bind each credential kind to that deployment through the service.
The `base` and `sdk-minimal` bundles mount the service, and the SDK server mounts it with its fallback route when the composition has none. Tests that mount a route plugin by hand mount the service first; the pinned row list of the `sdk-minimal` bundle gains the `deepseek-auth` row.
Conflicts were all in generated files and pairing records: the config
catalog, the dsh-doc package list, and the README records of
packages/client and ui-conversation. Each takes master's side and is then
regenerated, so it differs from master only by this branch's entries.
Also in this merge:
- ui-session-panel follows master's release to 0.2.2-rc.3, and the
lockfile is master's plus this package.
- The web-fetch-failure-row header capture, added on master, gains the
Session panel toggle.