Commit Graph
76 Commits
Author SHA1 Message Date
j-xiang 599e6edc87 docs(i18n): record proofread README pairs 2026-07-29 15:30:44 +08:00
j-xiang 90c75be466 docs(i18n): proofread README translations 21-40 2026-07-29 15:29:38 +08:00
Chinesezjc 8f06c561ee docs(code-runtime): state the maxWallMs upper bound in the public Config contract
The load-time range check rejects a maxWallMs above Node's maximum
setTimeout delay, but the constraint appeared only in the README design
section. Deployments reading the Config field JSDoc, the generated config
catalog, or the README config summary saw maxWallMs described as a
positive finite wall-clock ceiling, so an out-of-range value looked valid
until plugin load failed.
2026-07-27 19:53:57 +08:00
Chinesezjc 68f325ac48 Merge remote-tracking branch 'origin/master' into fix/worker-timer-clamp 2026-07-27 18:29:34 +08:00
Chinesezjc d3d66926fb fix(code-runtime): reject a maxWallMs above Node's maximum timer delay
`config.maxWallMs` is only checked for positivity, and it is handed to
`setTimeout`, which clamps any delay above 2^31-1 ms to 1 ms. A deployment
configuring a 25-day wall ceiling therefore gets the opposite of what it asked
for: every run times out on the first tick. The runtime now range-checks the
field at load against MAX_TIMER_DELAY_MS from dsh-timeout and throws, so the
misconfiguration fails loud where it is self-contained instead of silently
inverting the budget.

`computeMs` needs no matching bound: it is compared against measured event-loop
utilization rather than fed to a timer.

The test asserts both the rejection and that the boundary value itself loads.
2026-07-27 14:01:15 +08:00
Tianyi Cui c4647a8609 test: adopt execa for hand-rolled subprocess plumbing, parseArgs for llm-mock-server CLI, vi.waitFor for poll loops
Implements the execa Agent Note's four sub-changes:
- execa (root devDep + loader-smoke dep) replaces the hand-rolled
  spawn-collect-timeout choreography in loader-smoke, apps/cli and
  cli-demo/acp-demo built-bin e2e, lsp-local and code-runtime-worker
  built-lib e2e, the tui pty-harness outer collector, the jsonrpc
  keyless smoke, and crash-recovery's child spawn. Genuinely custom
  parts stay custom: cli-demo's interrupt-on-marker, jsonrpc's
  line-predicate protocol driving, crash-recovery's SIGKILL-at-failpoint.
  The two loader-smoke /* v8 ignore */ OS-error branches are gone.
- llm-mock-server CLI tokenizes via node:util parseArgs; numeric
  coercion/bounds/cross-option constraints stay manual; pinned
  error-message tests updated to the parseArgs texts.
- both loadRootEnv copies in apps/web/tests are deleted: the owning
  vitest configs (web unconditionally, snapshot in record mode)
  already load the repo-root .env before these files run.
- the four poll loops (acp-snapshot harness waits + crash-recovery
  waitForFile) ride vi.waitFor with explicit {interval, timeout}.
2026-07-26 22:29:41 +08:00
Tianyi Cui 226dc7a249 docs: translate remaining READMEs 2026-07-26 05:06:39 +08:00
Tianyi Cui 4aac1514e4 docs(code-runtime): cover captured error construction 2026-07-23 03:51:25 +08:00
Tianyi Cui 7809236236 fix(code-runtime): capture worker error intrinsic 2026-07-23 03:51:15 +08:00
Tianyi Cui ffbdabf39c docs(code-runtime): specify mutation-safe boundaries 2026-07-23 03:38:34 +08:00
Tianyi Cui a19c80bf6e fix(code-runtime): preserve typed failures after mutation 2026-07-23 03:34:42 +08:00
Tianyi Cui 8a8c2164fd fix(code-runtime): harden captured JSON boundary 2026-07-23 03:32:24 +08:00
Tianyi Cui f3b42fd738 test(code-runtime): type mutated array predicate 2026-07-23 03:11:53 +08:00
Tianyi Cui 27fe26f8d2 docs(code-runtime): record captured intrinsic boundary 2026-07-23 03:09:33 +08:00
Tianyi Cui 182e6a28cc test(code-runtime): cover malformed key markers 2026-07-23 03:09:13 +08:00
Tianyi Cui 4afcb5c3c9 fix(code-runtime): capture worker JSON intrinsics 2026-07-23 03:04:43 +08:00
Tianyi Cui a552a6ce63 test(code-runtime): cover revoked constructor spoof 2026-07-23 02:02:59 +08:00
Tianyi Cui e9e450a902 fix(code-runtime): reject forged container prototypes 2026-07-23 02:01:04 +08:00
Tianyi Cui 8379101e3b fix(code-runtime): keep worker helper private 2026-07-23 01:35:33 +08:00
Tianyi Cui fb74156cf8 fix(code-mode): generalize failures and bound diagnostics 2026-07-23 01:32:17 +08:00
Tianyi Cui 994bb4b07c fix(code-mode): render deep results iteratively 2026-07-22 19:57:44 +08:00
Tianyi Cui ef2de530ff fix(code-runtime): flatten worker JSON transport 2026-07-22 19:09:27 +08:00
Tianyi Cui d6f478488d test: allow deep worker checks under Windows coverage 2026-07-22 18:40:24 +08:00
Tianyi Cui 0852d5ab63 test: stabilize deep Code Mode worker coverage
Give the real-worker binding stress case an explicit CI budget and keep the forged-completion program pending so bootstrap cannot publish a competing normal completion.
2026-07-22 18:24:36 +08:00
Tianyi Cui f2d86b232e fix(code-runtime): accept deeply nested JSON 2026-07-22 02:13:37 +08:00
Tianyi Cui bb6709b14a fix(code-runtime): bound completion measurement 2026-07-22 01:42:41 +08:00
Tianyi Cui 865d7de858 fix(code-runtime): drain late worker pipe output 2026-07-22 01:27:03 +08:00
Tianyi Cui fc97403946 fix(code-runtime): contain deep output accounting 2026-07-21 22:54:12 +08:00
Tianyi Cui 8fd1201cfa fix(code-runtime): align worker JSON snapshots 2026-07-21 22:29:55 +08:00
Tianyi Cui 627eb6e00b fix(code-runtime): bound hostile output accounting 2026-07-21 21:56:38 +08:00
Tianyi Cui 379ac32401 fix(code-runtime): close outer boundary bypasses 2026-07-21 21:20:41 +08:00
Tianyi Cui eed5ff4dcf Merge branch 'codex/canonical-tool-output' into codex/code-mode-typed-results
# Conflicts:
#	docs/event-producer-consumer.md
#	docs/module-graph.md
#	packages/code-runtime/code-runtime-worker/package.json
#	packages/spill/spill-policy/package.json
#	pnpm-lock.yaml
2026-07-21 20:06:02 +08:00
Tianyi Cui 2623ddbee4 fix(code-runtime): validate arguments before worker dispatch 2026-07-21 18:19:07 +08:00
Tianyi Cui 1709b8cfee fix: keep source Code Mode worker self-contained
A direct runtime import of the session package made the unbuilt worker depend on sibling lib output. Use a parity-tested local JSON snapshotter and pin the isolated source closure with a real-worker test.
2026-07-21 05:19:40 +08:00
Tianyi Cui c1d7b0df81 feat: return typed values from Code Mode 2026-07-21 04:37:09 +08:00
Tianyi Cui f78b17a352 Merge branch 'codex/invariant-package-registration-gate' into codex/package-invariant-checks 2026-07-20 19:55:46 +08:00
Tianyi Cui 9c4cc05da6 Merge branch 'codex/invariant-service-seam' into codex/invariant-package-registration-gate 2026-07-20 19:48:51 +08:00
Tianyi Cui 1145ee5fc3 fix(invariants): assert runtime relationships, not API shapes 2026-07-20 19:34:19 +08:00
Tianyi Cui 3b7ce2e682 fix(invariants): require justified empty companions 2026-07-20 18:39:37 +08:00
Tianyi Cui 6eaa6073a2 test(code-runtime): stabilize slow-binding budget case 2026-07-20 17:32:17 +08:00
Tianyi Cui 684fcf3357 Merge branch 'codex/invariant-package-registration-gate' into codex/package-invariant-checks
# Conflicts:
#	.agents/notes/implemented/architecture/2026-07-19-package-invariant-runtime-contracts.i18n.yaml
#	.agents/notes/implemented/architecture/2026-07-19-package-invariant-runtime-contracts.md
#	.agents/notes/implemented/architecture/2026-07-19-package-invariant-runtime-contracts.zh.md
#	.agents/notes/implemented/architecture/2026-07-19-package-owned-invariant-service.i18n.yaml
#	docs/rfc/INDEX.md
#	packages/AGENTS.md
2026-07-20 00:54:28 +08:00
Tianyi Cui 941b0411d8 feat(invariants): implement package runtime checks 2026-07-20 00:38:37 +08:00
Tianyi Cui 6520f71f94 Merge remote-tracking branch 'origin/codex/invariant-service-seam' into codex/invariant-package-registration-gate
# Conflicts:
#	.agents/notes/implemented/architecture/2026-07-19-package-owned-invariant-service.i18n.yaml
#	docs/core-data-structures/session.md
#	docs/module-graph.md
#	package.json
#	packages/sdk/scripts/tsconfig.json
2026-07-20 00:35:06 +08:00
Tianyi Cui e8eddc7ef8 Rename RFCs to Agent Notes 2026-07-19 22:52:03 +08:00
Tianyi Cui 433670a754 feat(invariants): require package-owned companions 2026-07-19 22:13:50 +08:00
Tianyi Cui a278374e8f docs: structure model experience fields 2026-07-19 18:08:42 +08:00
Tianyi Cui bcc920369c docs: document package KV cache effects 2026-07-19 17:39:50 +08:00
Tianyi Cui 38ea10eee0 Merge remote-tracking branch 'origin/master' into codex/simp-prune-code-runtime-surface 2026-07-15 13:20:08 +08:00
imccyu 31f4441fd4 pkg: update vendor dep 2026-07-15 11:28:45 +08:00
Tianyi Cui 59c5010283 Merge branch 'codex/simp-prune-tools-prompt-surface' into codex/simp-prune-code-runtime-surface
# Conflicts:
#	docs/config-catalog.md
#	docs/cordis-catalog/services.md
#	docs/rfc/implemented/feature/2026-06-15-code-mode.md
2026-07-14 19:05:23 +08:00