deepseek-harness/packages/subagent/subagent-inprocess/tests
Chinesezjc 24dd48b133 fix(tools): collapse code-mode executor to run_code for model-direct calls
wireSchemas() already advertised only run_code under mode: 'code', but the
executor resolved every call through get(), which returns the full visible
map plus the reserved transport. A model could name a native tool directly
and bypass run_code entirely. Route the execution-path lookups through a
new private resolveExecution() that applies the mode collapse at the
operation boundary: model-direct calls under 'code' may only name run_code
(UNKNOWN_TOOL otherwise), while SDK sub-dispatches (parent token set) keep
every visible tool. get()/schemas() public semantics are unchanged.

The denial happens at createExecution, before the extensible policy
pipeline — pre-execute listeners, approval ask, and guards never observe
a call that is deterministically denied. A collapsed call honors the
pre-dispatch cancellation contract, routes aborted results through the
visible tool's finalizeContent, and captures the finalizer before
argument materialization.

Regenerated docs, catalogs, graphs, scoped events, re-recorded
translation pairs, and updated test assertions.

Fixes #1815
2026-08-11 22:40:36 +08:00
..
fixtures fix(apiproxy): echo the preset a created session runs, not its header 2026-08-10 19:28:40 +08:00
inheritance.spec.ts Merge remote-tracking branch 'origin/master' into fix/continuable-subagent-policy-inheritance 2026-08-10 22:24:56 +08:00
preset-inheritance.spec.ts build(vendor): rescope the vendored Cordis packages into @deepseek-ai 2026-08-10 22:04:13 +08:00
structured.spec.ts Merge remote-tracking branch 'origin/master' into fix/continuable-subagent-policy-inheritance 2026-08-10 22:24:56 +08:00
subagent-inprocess.spec.ts fix(tools): collapse code-mode executor to run_code for model-direct calls 2026-08-11 22:40:36 +08:00