mirror of
https://github.com/deepseek-ai/deepseek-harness.git
synced 2026-08-29 04:26:38 +00:00
Tighten the startup sweep to backend-generated name shapes and fix the tests
that had drifted from the SweepRoot-based API:
- Match roots by the exact `dsh-spill-<6>` mkdtemp shape and session dirs by
`session-<12 hex>` (DEFAULT_ROOT_RE / SESSION_DIR_RE), replacing loose
startsWith checks so foreign or fixture-shaped directories are never swept.
- Carry `SweepRoot { path, pruneWhenEmpty }` through SweepOptions so a discovered
prior-default root is removed once emptied while the active root is never
pruned; lstat each session entry so a symlinked session dir is not followed.
- Fix the tests to the SweepRoot API: import SweepRoot, correct the gatherRoots
override return shapes, build discovery fixtures with the real mkdtemp shape,
and route the warn-wiring test through a deterministic failure path.
spill/ — tool-output spill capability family
English | 中文
This family persists oversized tool output and replaces the inline result with a bounded preview and retrieval locator.
| Package | Role | ctx key |
|---|---|---|
spill/ |
Defines spill storage | ctx.spillStore |
spill-local/ |
Stores spilled text in session-scoped local files | registers on ctx.spillStore |
spill-policy/ |
Applies the post-execution spill policy | listens on ctx.tools |
See the tool-output spill decision for the boundary between storage, retention, and tool-owned output handling.
The subsystem reference — SaveTextSpill, owners/sources, the branded locator — is docs/subsystems/spill.md; rationale in the tool output spill Agent Note.