Commit Graph

5193 Commits

Author SHA1 Message Date
Tianyi Cui
d404609e19 docs(subprocess): bring the zh side of the consumer-migration pairs along
The parent branch's zh translations were recorded against its pre-reshape
en text; this PR's Node-ward en deltas get minimal zh updates across the
subprocess catalog and the subprocess/lsp-local/subagent READMEs (all
type-equiv blocks byte-identical), with pairing records re-recorded.
2026-07-26 22:54:44 +08:00
Tianyi Cui
1b9d66eaac Merge branch 'worktree-process-service-seam' into worktree-subprocess-consumers
# Conflicts:
#	docs/core-data-structures/subprocess.md
#	packages/subagent/subagent-subprocess/README.md
#	packages/subprocess/README.md
#	packages/subprocess/subprocess-local/README.md
#	scripts/translation-pairing.manifest.json
2026-07-26 22:04:14 +08:00
Tianyi Cui
a238c4b064 docs(subprocess): bring the zh side of the subprocess pairs along after the master merge
Master made bilingual pairing mandatory repo-wide; the subprocess family
docs get their zh counterparts: new pairs for the core-data subprocess
catalog and the three subprocess READMEs (switcher lines added on the en
side), and minimal zh updates for the packages/bash/bash-local README
deltas this PR made, with pairing records recorded.
2026-07-26 22:00:38 +08:00
Tianyi Cui
3bd4a9afa6 docs: raise the AGENTS.md ceiling to 1690 for the subprocess group row
Master's layout block already sits exactly at the 1680-word ceiling; this
PR's one new line (the subprocess/ package group) is seven words the doc
genuinely needs, so the ceiling moves just far enough to admit it.
2026-07-26 21:11:13 +08:00
Tianyi Cui
4d733c8cbb Merge branch 'worktree-tasks-service-seam' into worktree-process-service-seam 2026-07-26 21:05:15 +08:00
Tianyi Cui
d0aebc9f92 docs(tasks): bring the zh side of the tasks pairs along after the master merge
Master made bilingual pairing mandatory repo-wide; this PR's seam-split
edits to the tasks docs get their zh counterparts: a new pair for the
dsh-tasks-local README and minimal updates to the tasks core-data doc,
agent-spine-demo README, and the tasks family READMEs, with pairing
records re-recorded.
2026-07-26 20:59:05 +08:00
Tianyi Cui
202582d600 Merge branch 'worktree-tasks-service-seam' into worktree-process-service-seam
# Conflicts:
#	packages/bash/bash-local/README.md
#	scripts/doc-budgets.manifest.json
#	scripts/type-equiv.manifest.json
2026-07-26 20:55:58 +08:00
Tianyi Cui
05ef4ffa9b docs(subprocess): zh wording refinements on the two seam notes
Faithfulness pass from the translation review: 接入 over 搭乘, first-mention
disposition annotation, 原始的 Readable/Writable, 留在原地, 评审 over 审阅;
pairing records re-recorded.
2026-07-26 20:35:41 +08:00
Tianyi Cui
f2972e846d fix(subprocess): keep awaited tree waits and the pending SIGKILL ref'd (Codex round 2)
An awaited waitForExit()/dispose() must hold the event loop open until the
tree really exits: with the liveness tick and the escalation timer unref'd,
a parent with no other live handles could exit claiming quiescence and
orphan the survivors it promised to reap. The escalation's pending SIGKILL
is a commitment; it self-bounds at graceMs. Module graph picks up the
subprocess-local -> timeout edge.
2026-07-26 20:34:57 +08:00
Tianyi Cui
c3394d3012 Merge remote-tracking branch 'origin/master' into worktree-tasks-service-seam
# Conflicts:
#	packages/tasks/README.md
#	packages/tasks/tasks/README.md
#	scripts/translation-pairing.manifest.json
2026-07-26 20:28:37 +08:00
Tianyi Cui
79a28ad6d9 fix(subprocess): tree-scoped escalation and byte-exact tails (Codex round 1)
(A1) terminate()/dispose()/service teardown keyed on direct-child settlement
could leak a TERM-trapping descendant that outlived the leader (Codex
reproduced it with a disowned trap-SIGTERM helper). kill()/terminate() now
gate on tree liveness instead of outcome settlement; the SIGKILL escalation
timer survives settle (unref'd, re-probing the tree); dispose's tier
quiescence is whole-tree exit via a bounded waitForExit; the service's live
set releases handles only when their tree is gone, and its teardown awaits
tree exit. Three new suites pin the survivor scenarios end to end
(terminate, dispose, service teardown).

(A2) the escalation branch is now real tested behavior — its ignore is gone;
the one remaining signalTree guard ignore states why it is unreachable
through the handle verbs.

(A3) docs contradictions fixed: the impl README's stale POSIX-only bullet
now states the contained best-effort Windows tree story; the lsp-local
README no longer claims taskkill failures stay visible (containment + the
tree-liveness wait is the actual contract); the architecture tables (en+zh)
list all three consumer families.

(B1) OutputCollector keeps a byte-exact tail across uneven chunk boundaries
(trim the head chunk instead of dropping it whole) — the LSP diagnostic-tail
contract; pinned by a cross-chunk test.

(B2) the subagent-acp coverage ignore is narrowed to exactly the
never-settling success arm.
2026-07-26 16:50:36 +08:00
Chinesezjc
3586422b69 Merge pull request #646 from deepseek-harness/fix/intent-draft-sync-echo
fix(web): IME composition corrupts the "Let's start building" composer
2026-07-26 16:16:56 +08:00
Tianyi Cui
c80fddf7a6 docs(subprocess): final translation pass on the consumer-migration note 2026-07-26 16:16:43 +08:00
Chinesezjc
cdccf69f4b Merge remote-tracking branch 'origin/master' into fix/intent-draft-sync-echo 2026-07-26 16:05:46 +08:00
Tianyi Cui
3c98ade986 docs(subprocess): bilingual pair for the consumer-migration Agent Note
Adds the zh counterpart, aligns the seam note's zh side with its updated
interface bullet and follow-up sentence, records both pairs, and ratchets
the translation-pairing manifest.
2026-07-26 15:51:24 +08:00
Tianyi Cui
785efe03e3 Merge pull request #651 from deepseek-harness/worktree/i18n-complete-non-readme 2026-07-26 15:38:00 +08:00
Tianyi Cui
3672cd25b4 feat(subprocess): migrate lsp-local, subagent-acp, and the env scrubs onto the seam
Review direction (tianyicui, PR #660): in a stacked PR, change all other
process-running places to use the new service.

- lsp-local: LspConnection spawns through ctx.subprocess (piped protocol
  streams + a no-spill collected stderr tail); its private process-tree
  helpers (POSIX group signalling, Windows taskkill, liveness polling) are
  deleted in favor of the seam's handle verbs, and its buildChildEnv now
  rides scrubbedParentEnv (LSP children also stop inheriting stale DSH_*).
  The plugin injects 'subprocess'; compositions/tests mount
  dsh-subprocess-local.
- subagent-acp: the ACP child spawns through the seam (piped ndjson streams,
  inherited stderr); spawn failure surfaces through done-rejection into the
  same startup race; disposal is handle.dispose with the plugin's configured
  graces. dsh-subagent-subprocess is DELETED — its dispose ladder and scrub
  are the seam's, and the isolated-config-dir helper had no consumer.
- mcp-client, pty-local, sdk-helper: adopt scrubbedParentEnv as the one
  scrub definition (their spawns stay put by ownership: the MCP SDK and
  node-pty own those calls; the SDK wizard runs outside any composition).
- Coverage: per-file 100% over every touched src file, with each v8 ignore
  carrying a platform or contract reason; new suites cover stdio
  dispositions, the dispose ladder tiers, injected-win32 tree semantics,
  waitForExit, settled-kill/terminate no-ops, and spawn-failure disposal.
- Docs: consumer-migration Agent Note (en; zh follows in this PR), seam note
  updated in place, subprocess.md rewritten for the reshaped vocabulary
  (type-equiv re-registered), READMEs and SERVICE_ROLES updated, taskkill
  added to knip ignoreBinaries.
2026-07-26 15:27:59 +08:00
Chinesezjc
9ef532ea34 Merge remote-tracking branch 'origin/master' into fix/intent-draft-sync-echo 2026-07-26 15:22:07 +08:00
Tianyi Cui
b4d032c1a2 docs: make bilingual pairing universal 2026-07-26 15:06:51 +08:00
Tianyi Cui
df8756ccf5 Merge remote-tracking branch 'origin/master' into worktree/i18n-complete-non-readme
# Conflicts:
#	packages/client/i18n/README.md
#	packages/client/locale/README.i18n.yaml
#	packages/client/locale/README.zh.md
#	packages/client/ui-layout/README.md
#	packages/client/ui-theme/README.md
2026-07-26 14:37:46 +08:00
Tianyi Cui
fd7e6d4d11 Merge subprocess label fixes into the consumers branch 2026-07-26 14:11:39 +08:00
Tianyi Cui
e678db440e fix(subprocess): finish the rename in current-state docs and graph inputs
Codex re-review (A): AGENTS.md layout tree, the architecture capability
tables (en+zh), the seam Agent Note's group-name sentence (en+zh), and the
SERVICE_ROLES entry still carried process/-era labels; regenerated the doc
graphs and config catalog from the corrected inputs.
2026-07-26 14:10:46 +08:00
Tianyi Cui
12a7e38417 feat(subprocess): reshape the seam Node-ward for multi-consumer use
Review direction (tianyicui, PR #660): make the interface closer to Node's
API so the other process-running places can adopt it. The spec gains
per-stream stdio dispositions — 'pipe' (raw Readable/Writable for protocol
streams), 'inherit' (diagnostics to the parent), and collect mode ({maxBytes,
spill?} — the old bounded tail-keep shape, now with spill optional for
diagnostic tails). SubprocessOutcome carries exit facts only; collected
output stays readable through handle.collected after settlement (spill fds
are sealed at the settle boundary). The handle grows Node-style kill(signal)
(single signal, tree-scoped, no-op after settlement), terminate() (the
SIGTERM→grace→SIGKILL escalation, also driven by the spec signal),
waitForExit() (tree liveness, not just the direct child), and dispose()
(the cooperative stdin-EOF→SIGTERM→SIGKILL ladder from subagent-subprocess,
graces caller-supplied). Tree semantics are platform-correct: POSIX detached
groups with direct-child fallback; Windows taskkill /T with an injectable
runner. scrubbedParentEnv/SENSITIVE_ENV_PATTERN move to the seam as the one
shared scrub definition.

bash-local maps its config onto collect modes and batch stdin and reads
results through the collected readers; its kill() maps to terminate() so
task_kill keeps escalation semantics.
2026-07-26 14:07:42 +08:00
imccyu
92700c2375 Merge pull request #644 from deepseek-harness/worktree-websettings
Slot-composed settings surface with locale and theme preferences
2026-07-26 13:59:14 +08:00
Tianyi Cui
030973e4ab Merge branch 'master' into worktree/i18n-complete-non-readme 2026-07-26 13:31:20 +08:00
imccyu
0fe9ff888d Merge origin/master into worktree-websettings
ui-sidebar shell landed on master (#643: geometry-only shell, the
browsing region moved to the sidebar.workspaces slot); this branch's
sidebar.settings foot seat re-applies on top — the hardcoded foot row
becomes the seat, the seat rides the railIn crossfade, and the shell
spec's renderSlot stub key-splits region vs settings.
2026-07-26 13:15:57 +08:00
Tianyi Cui
847131e4fd Merge pull request #643 from deepseek-harness/worktree-ws-more 2026-07-26 13:06:55 +08:00
Tianyi Cui
8d078d7f64 Merge branch 'master' into worktree-ws-more 2026-07-26 13:01:36 +08:00
Tianyi Cui
5e6edce4ed fix(subprocess): finish the rename in generated api-catalog and built-bin closures
CI caught two rename escapes: the regenerated api-catalog.ts had not been
committed after the LINK_MAP retarget, and the built-bin e2e consumer
closures still linked packages/process/* directory paths.
2026-07-26 12:57:14 +08:00
imccyu
fabc843c22 docs(gui): regenerate graphs for the returning ui-settings-general package 2026-07-26 12:48:30 +08:00
Tianyi Cui
fc566119a7 refactor(subprocess): rename the process seam to subprocess and address review
Review feedback (tianyicui): 'process' is a poor service name. The family is
now packages/subprocess/ — @deepseek-ai/dsh-subprocess (ctx.subprocess,
abstract SubprocessService, Subprocess* vocabulary) and
@deepseek-ai/dsh-subprocess-local (LocalSubprocessService) — renamed
throughout code, compositions, docs (en+zh, pairs re-recorded), catalogs,
and gates. 'subprocess' is the precise term for managed OS children (the
Python-stdlib sense), avoids colliding with Node's global process object,
and reads as one system beside dsh-subagent-subprocess.

ds-review-bot findings addressed:
- kill() on a settled handle is now a no-op (no signal to a possibly-reused
  pgid, no referenced grace timer delaying exit); pinned by a spy test.
- The moved DshEnvironmentKey/DshEnvironment/CollectedOutput types get
  drift-checked type-equiv blocks on the new subprocess.md page, restoring
  their manifest registration.
- subprocess.md is registered in the core.md sub-page index (en+zh).
2026-07-26 12:43:59 +08:00
imccyu
7e20322c40 docs(notes): retitle the rejected alternative as per-feature satellite packages
The rejected shape is a settings satellite per feature; the ownerless
copy stays with ui-settings-general, which carries no feature surface.
2026-07-26 12:43:17 +08:00
imccyu
a04a223bab refactor(gui): copy-free settings shell; ui-settings-general owns ownerless copy
The shell is now a pure composition face: no dictionaries, no locale
dependency, and three new chrome content seats (settings.trigger /
settings.header / settings.close) whose slot content also carries the
accessible names (trigger text, dialog aria-labelledby, visually hidden
close label). ui-settings-general returns as the owner of copy that
belongs to no single feature: chrome content, the General section with
its item slot, and the settings dictionaries. Slot types split homes —
trigger/header/close/section live in the shell contract; the
settings.general.item entry moves to the locale package (the common
dependency of every item registrant), with ui-theme consuming it
through a re-export seam; the verbatim duplicate merges are gone and
the dependency graph is a clean DAG.
2026-07-26 12:40:17 +08:00
Tianyi Cui
8f75565f03 Merge tasks-seam diagnostics fix into the subprocess branch 2026-07-26 12:21:13 +08:00
Tianyi Cui
1bc090fe00 fix(tasks): producer diagnostics name the seam, not one implementation
Review feedback (tianyicui, PR #657 inline): the missing-service message
should mention dsh-tasks, which defines ctx.tasks, rather than promoting a
specific backend. The seam's own surfaces (README, the direct-mount fence)
keep pointing at implementations, so the pointer chain still lands on
dsh-tasks-local without the producer strings going stale when another
backend becomes the recommended default. Agent Note updated accordingly
(en+zh, re-recorded).
2026-07-26 12:17:45 +08:00
imccyu
9a4be33899 docs(notes): record slot-declaration-as-service as future work
deferRegistration() stays the shipped form; the note pins the follow-up
direction (bridge declarations into slot:<name> services, migrate
registrants to nested ctx.inject, delete the helper) and the boundaries
a separate PR must settle.
2026-07-26 12:09:38 +08:00
Tianyi Cui
a976a3e64a Merge remote-tracking branch 'origin/master' into worktree/i18n-complete-non-readme 2026-07-26 12:08:40 +08:00
Tianyi Cui
80d5c118ac Merge pull request #655 from deepseek-harness/worktree/i18n-complete-readmes
docs: complete bilingual README coverage
2026-07-26 12:06:01 +08:00
Tianyi Cui
4c3e4d172f Merge pull request #635 from deepseek-harness/codex/require-pr-labels
docs: require appropriate PR labels
2026-07-26 11:50:53 +08:00
imccyu
08251eb180 Merge branch 'master' into worktree-ws-more 2026-07-26 11:20:05 +08:00
imccyu
15c0b6290b docs(notes): state the rejected per-section split without implementation history 2026-07-26 11:18:46 +08:00
Tianyi Cui
2d2bf87192 fix(process): CI follow-ups — built-bin closures and gate-safe path prose
- The acp-demo and cli-demo built-bin e2e consumers link a pruned package
  closure; add process/process and process/process-local so the built bins
  boot now that bash-local injects ctx.processes.
- verify-package-paths scans backticked packages/* references, so the
  timeout-note's historical mention of the deleted run.ts path is reworded
  (en+zh, both sides now carry the same historical-vs-current split; the
  earlier zh edit had silently missed its match); pair re-recorded.
2026-07-26 08:17:18 +08:00
Tianyi Cui
bd462ff2b5 docs(process): apply the timeout-note clarification to the English side too
The previous commit's English edit silently missed (its match pattern
targeted already-rewritten text); only the zh side carried the split. Both
sides now state it and the pair is re-recorded.
2026-07-26 08:07:53 +08:00
Tianyi Cui
65cd40e764 docs(process): unambiguous past-tense in the timeout-library note
Codex round-2 (B): the retargeted bullet read as though spawn.ts carries the
full timeout plumbing today. Split the historical claim (run.ts, pre-library)
from the current split (spawn.ts reacts to aborts; bash-local owns the fused
deadline and classification), en+zh, pair re-recorded.
2026-07-26 08:03:34 +08:00
Tianyi Cui
fb0d4ba564 fix(process): close review gaps from Codex round 1
- Mount LocalProcessManager in the sandbox e2e compositions (bwrap/landlock/
  seatbelt + the spine multi-project e2e) and add the spine demo's
  dsh-process-local devDependency, so SandboxBashExecutor's new inject
  resolves when those suites are enabled.
- Extend the Windows test/coverage skip to packages/process/* — the POSIX
  process-group suite moved there from packages/bash.
- Update the stale disposal contract: the bash seam JSDoc, BashProcess JSDoc,
  and core bash doc (en+zh) now state that composition teardown (the process
  manager's disposal) owns kill-and-await, and an executor-only reload leaves
  background processes running.
- Record ctx.processes in the architecture capability table and extension map
  (en+zh) and the root AGENTS.md layout tree; reword the timeout-library note
  so it describes where the plumbing and classification live today.
2026-07-26 07:54:42 +08:00
Tianyi Cui
1f0b8cc4c1 Merge tasks-seam review fix into the process-seam branch 2026-07-26 07:28:02 +08:00
Tianyi Cui
13ce23db4b docs(process): final translation pass on the process-seam note zh counterpart 2026-07-26 07:27:33 +08:00
Tianyi Cui
3b91135923 fix(tasks): fail loud when the abstract seam is mounted directly
Review finding (Codex round 1): abstract erases at runtime and
@deepseek-ai/dsh-tasks used to be the mountable registry, so a stale
composition row would register a ctx.tasks with no method implementations
and fail far from the misconfiguration. The seam constructor now rejects
direct mounts with a load-time pointer at dsh-tasks-local; the seam suite
pins the fence, the Agent Note cost paragraph records the actual behavior,
and the stale tool-pty README requirement line names the implementation
package.
2026-07-26 07:25:47 +08:00
Tianyi Cui
e20545c9ee fix(tasks): fail loud when the abstract seam is mounted directly
Review finding (Codex round 1): abstract erases at runtime and
@deepseek-ai/dsh-tasks used to be the mountable registry, so a stale
composition row would register a ctx.tasks with no method implementations
and fail far from the misconfiguration. The seam constructor now rejects
direct mounts with a load-time pointer at dsh-tasks-local; the seam suite
pins the fence, the Agent Note cost paragraph records the actual behavior,
and the stale tool-pty README requirement line names the implementation
package.
2026-07-26 07:20:45 +08:00
Tianyi Cui
0d6bfd8856 refactor(process): split the process manager out of the bash executor
New process/ capability family: @deepseek-ai/dsh-process owns ctx.processes —
abstract ProcessManager.spawn(spec) over a fully-explicit ProcessSpawnSpec —
plus the shared DSH_* managed-environment and CollectedOutput vocabulary;
@deepseek-ai/dsh-process-local carries the former bash-local run.ts plumbing
(detached groups, tail-keep spill-backed output, credential scrub, kill
escalation, kill-and-join disposal) with no config of its own.

dsh-bash-local becomes a consumer: it keeps command defaulting, the fused
deadline timedOut/aborted classification, the model-friendly terminal env
(now merged through the ordinary env channel), and the [stderr]-marked
background read merge, and spawns through ctx.processes. Background-process
lifetime moves to the manager, so an executor reload no longer kills live
background work; a background spawn failure is injected once into the read
path instead of being buffered as fake stderr. dsh-bash re-exports the moved
vocabulary so bash consumers keep one import root; dsh-bash-sandbox only
redeclares the inherited inject.

Every composition loading a bash executor now loads dsh-process-local (CLI,
examples, python bundled runtime, create-sdk bash feature, inline test
configs).
2026-07-26 06:59:01 +08:00