Repository navigation
Record native Codex task requests once (T56) - #223
Merged
Merged
Conversation
This was referenced Oct 14, 2026
erickb336
marked this pull request as ready for review
October 14, 2026 05:22
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Closes #221
Sage task T56
The Codex chief can record a task through
sage_create_task. An identical request returns the original task, including after reconnect. A changed request is refused. Task creation grants no run, dispatch, review or merge permission.The provider supplies the authenticated owner and fixed logbook. Core saves the task, route decision and request receipt under one recoverable publication. Readers reject partial writes and detect publication between table reads. CLI and native creation share the task-frame rules. Claude #140's active functions are unchanged.
Validation
Final head
7935364passes build/check and 31 focused tests. Its exact-commit native task-creation probe passes: one task, one decision, exact retry, zero runs/reservations/children and temporary-profile cleanup. Two clean independent code/security/QA cycles are complete on this unchanged head. All 1,267 local tests pass. Exact-head CI run 38515416318 passes all 1,267 tests.Commands ran with fake
ps,pgrepandkillfirst on PATH andNODE_TEST_CONTEXTunset:npm run build: 299 files.npm run check: all checks pass.node --test --test-name-pattern='native task creation|T56:' scripts/codex-server.test.mjs: 31 pass, 0 fail.SAGE_TEST_MACHINE_ID=native-fixture node scripts/probe-codex-lifecycle.mjs --sage-create-task: verified true, exit 0, temporaryRootRemoved true.npm test -- --test-concurrency=1: 1,267 pass, 0 fail, 0 cancelled, 0 skipped.Regression evidence:
All 31 tests (14 top-level groups and 17 nested cases) fail on detached main
47146febecause the task-creation module is absent. This demonstrates missing API coverage, not 31 behavioral regression failures.Two scratch mutations remove only snapshot-version comparison. Both tests fail: a concurrent publication incorrectly permits a merge, and the logbook reader no longer refuses the mixed snapshot.
On
cb4abeb, checksum-valid receipts containing null, false, zero or an empty string create an extra task before refusal. The new regression checks unchanged tables, receipt bytes and pending state. Four truthy malformed controls already refused.On
426feb4, the patternmalformed saved task resultsreports 0 pass / 6 fail, andrecovery preflightsreports 0 pass / 5 fail. The failures show publication before refusal or missing refusal. Final recovery preflight validates the complete update before any table publication. These are format-integrity controls; a hostile writer with direct logbook access is outside this boundary.Snapshot mutation reproduction: in an isolated copy, remove only the receipt-version comparison while retaining
taskWrites.readVersion(dir). Run the patternT56: (merge|logbook) refuses: 0 pass / 2 fail.Detached-main reproduction: copy only the final test file into a detached main checkout, link test dependencies, and run the same focused command. No production code is copied.
The earlier full run on
426feb4was interrupted after review found another defect. It is not passing evidence.Not verified: real-model choices, installed automatic Sage, all lifecycle routes, or old installations without the pending-write guard. Native fixtures use simulated model responses. Full support remains tracked in #88 and #138. All owned local test and probe processes finished; temporary proof checkouts and native profiles were removed.