Skip to content

fix(codex): prepare web search policy before harness dispatch - #174774

Merged
steipete merged 7 commits into
mainfrom
codex/stab-codex-websearch-policy-prep
Oct 19, 2026
Merged

steipete merged 7 commits into
mainfrom
codex/stab-codex-websearch-policy-prep

Conversation

@steipete

@steipete steipete commented Oct 16, 2026 •

Copy link
Copy Markdown
Contributor

What Problem This Solves

Deleting another agent can make a healthy agent's Codex turn fail with Session capability metadata requires worker preparation. Preparing search policy in core fixes that lookup, but the resulting allowance must remain bound to the native model and requester facts it was computed from.

A model switch or requester revocation between preparation and native capture could previously enable hosted search with stale policy. Compaction also performed an unused search lookup with different execution and sandbox-policy owners.

User Impact

Healthy Codex turns use core's worker-prepared search policy. A changed native model or requester now rejects the stale operation before native thread/turn writes with an actionable retry message. Compaction keeps its existing execution owner and skips unused search preparation.

Why This Change Was Made

This preserves the maintainer's prepared-data decision: optional preparedWebSearchPolicy data on existing attempt parameters, with no new SDK export, callable policy capability, or capability version. Existing no-field and two-boolean SDK callers remain source-compatible. Codex still applies per-turn tool caps and memory-flush restrictions.

Core records the exact model tuple and requester policy/lineage reads used during preparation. The existing native-policy owner compares them with captured/current facts, retains keyed and ID-selector source checks, and synchronously asserts them at the physical native write, including absent or reassigned IDs and pending worker publications. A mismatch never consumes the old allowance or falls back to synchronous policy resolution. The native requester-admission prerequisite from #176352 is included.

Evidence

Current candidate: 2d00df6de14265b781d878ee14e37451e6e0b845, including the session-ID native-admission repair and the follow-up cold-storage correction. The earlier CI run 39198024879 exposed four cold-storage lifecycle failures: durable ID-selection authority was incorrectly classified as native-only, so manual compaction rejected it. The same file passed 35/35 on both Node and Bun at main parent 6e4883fca44e. The current fix preserves native classification for memory-backed sources while allowing durable ID-selected authority through worker compaction. The restoration-race fixture now injects its mutation at the actual prepared assertion; its refusal and archive-preservation checks are retained.

Current-candidate proof: 213 test passes: cold storage 36/36 on Node and 36/36 on Bun, native transport 9/9, session owners 29/29, and Codex app-server 103/103. All eight stale-authority native cases make zero native writes; the allowed case makes two writes with cached search. The new direct ID-selected cold-compaction test failed before the production correction and passes afterward. Core, Codex and scoped test types, shipped SDK v2026.10.5 surface/export checks, zero-cycle check, and touched lint/format/whitespace checks pass. Independent full-branch Codex autoreview is scoped-clean through P2, with no findings and the verdict “patch is correct” (0.86). Production correction: +3/-3; no new SDK signature, export, protocol, config, storage format, or F78 change. ClawSweeper Revision 14 explicitly clears the session-ID P1 and prior security hold on this exact head, with no remaining findings; its review accepts the supplied native and cold-compaction proof. Broad CI remains a separate gate.

Current CI attribution: 39206346345 tests head 2d00df6de142 through merge d124b88ea9d7af9348a8571d046da643ec131e37 into main fbc4e3a20f52. Job 117910334772 fails only src/gateway/talk/client-authority.test.ts > steers a GA chat-owned Talk run captured before backend publication=true, expecting tool_authority_mismatch but receiving no_active_run. Scheduled main 39205204421 at e3cc361b27cb has the identical case and failure signature, and the test blob is unchanged between that main, the CI base, and the tested merge. This is an inherited CI failure, not passing CI; the native inherited-failure exception may be used only after every remaining job finishes and its gates are satisfied. No CI rerun or synthetic push was used.

Latest reviewed candidate: 7c788f06256ced8fb3292159d4092b8c3b63bf4e, merging main 6e4883fca44ed3e8174b4dfef16ee17e03ba1621 into 97b231c1bed1ee13046e1645b41955a73674ebb8 to resolve the GitHub conflict. The one manual resolution preserves the prepared model guard and requester binding alongside main's asynchronous recovery lookup from #176707. No rebase.

Post-merge proof: 69 focused tests passed across the real native transport (9), deletion/policy preparation (2), execution policy (22), native-model lifecycle (18), and web-search tool construction (18). All eight stale-authority native cases reject with zero thread/turn writes; the unchanged case completes with two writes and cached search. Core and Codex types, targeted lint/format, and whitespace checks pass. Independent full-candidate Codex review is scoped-clean through P2, “patch is correct.” The test wrapper completed all four shards and verified its compiler outputs (868.32 seconds total).

Session-ID repair head: 97b231c1bed1ee13046e1645b41955a73674ebb8. It fixes the session-ID admission finding by retaining ID selection (including absence) in the existing session-currentness owner through the synchronous physical-write assertion. ID-affecting worker commits pending host publication also invalidate admission. The former asynchronous-only ID path is removed. See the finding reply.

At this head, all 9 recording-JSON-RPC native-boundary tests pass, including late absent-to-present and reassignment controls; all 19 session-owner tests and 103 Codex app-server tests pass. Core, Codex-source and scoped test types; SDK surface/export synchronization and scoped source compatibility; lint/format; docs links; and zero-cycle checks pass. Independent committed-branch Codex review is scoped-clean through P2, with no findings and the verdict “patch is correct.” The optional ID selector extends the existing helper additively; previous key-only helper and no-field/two-boolean prepared-policy callers compile unchanged.

The native late-ID controls fail on the preceding b833540890ec head because a stale allowance reaches the native write. The pending-publication control also fails before the publication guard is added. Final native proof requires zero writes for changed authority. No live provider or operator Gateway was used. Broad CI and ClawSweeper security re-review for the merged head remain required before landing.

Historical CI: 39186087240 passed at b833540890ecbaa06071a166ffa30b3d0c6b3518, after repairing the direct test-API import and widened binding literal reported by 39184092677. This is prior-head evidence only.

Prior-head proof at 10efe93144a47fbe52da0338557454791509ffef: local recording-JSON-RPC proof uses real core preparation, persisted requester updates, the real Codex harness and binding lifecycle, and real native write admission. No live model provider or operator Gateway was used.

Native case Thread/turn writes Result
Unchanged model 2; search cached Completed using prepared policy; no synchronous resolver call
Native model changed during worker preparation 0 Rejected
Requester revoked at native write admission 0 Rejected
Requester reassigned at native write admission 0 Rejected
Requester revoked after core preparation, before native capture 0 Rejected

A supplemental sixth case captures a real missing-ID read, inserts a restrictive row under another key at native admission, and requires zero native writes. It isolates the ID-selector/transport contract.

On the preserved WIP before requester binding, the fifth case fails with two native writes, search cached, and a completed turn (325.25s command wall time). The earlier published-head controls also fail for the native-model switch and the compaction owner mismatch.

All 12 individually invoked Node-runtime suites pass: selection (91), execution environment (22), base dynamic-tool-build (74), web-search dynamic-tool-build (18), sandbox dynamic-tool-build (6), native authority (13), provider review (14), capability store (10), prefix stability (5), host model execution (18), original deletion regression (2), and native boundary proof (6): 279 tests passed. Core and Codex source types, SDK surface/exports, Madge (zero cycles), touched lint/format, docs, and diff/line-cap checks pass.

Independent committed-branch Codex autoreview is scoped-clean through P2, with no findings and the explicit verdict “patch is correct.” Production delta over the previously published head is +273/−72 (net +201); the whole PR is +322/−80 (net +242). The additional code records the original requester facts and carries their currentness check through existing native admission; it adds no state owner or storage format.

Direct source types and SDK surface/exports are checked locally; packaged SDK declarations remain CI-owned. No new storage, config, protocol, SDK export, or model-facing prompt text is introduced. Pending native supervision without a selected model retains its documented existing policy-resolution path and deletion-time limitation.

Known limitation: /btw side-runs and native-auth supervision without a modelRef retain the pre-existing unbound policy fallback; binding these paths to prepared data is tracked separately as F78 after this PR lands, consistent with #176352’s exclusion of re-resolving every ancestor policy edit.

@clawsweeper

clawsweeper Bot commented Oct 16, 2026 •

Copy link
Copy Markdown
Contributor

🦞👀
ClawSweeper picked this up.

Pull request received. I will update this pull request when review starts.

ClawSweeper review complete

ClawSweeper finished reviewing this revision. The review result is being finalized.

View the workflow run.

@chatgpt-codex-connector

chatgpt-codex-connector Bot commented Oct 16, 2026 •

Copy link
Copy Markdown
Contributor

Codex Review Summary

This comment shows the latest Codex review activity on this pull request.

Review Status Commit Review trigger
📝 Code Review ✅ Completed 2026-10-19T05:52:28.783450Z 2d00df6 New commits
ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review" or "@codex security review".

Codex reacts with 👀 while any review is running, comments if it has suggestions, and reacts with 👍 once all reviews finish with no findings.

@github-actions

github-actions Bot commented Oct 16, 2026 •

Copy link
Copy Markdown
Contributor

Security-sensitive guard cleared

Current revision: 2d00df6de14265b781d878ee14e37451e6e0b845

This PR no longer changes files in the maintainer security-review tier.

Separate CODEOWNERS requirements still apply to security policy and enforcement files.

@openclaw-barnacle openclaw-barnacle Bot added docs Improvements or additions to documentation scripts Repository scripts agents Agent runtime and tooling extensions: codex size: S labels Oct 16, 2026

@chatgpt-codex-connector chatgpt-codex-connector Bot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

💡 Codex Review

Here are some automated review suggestions for this pull request.

Reviewed commit: eb0922e550

ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".

Comment thread src/plugin-sdk/agent-harness.ts Resolved
@clawsweeper clawsweeper Bot added clawsweeper:intake:bug Preliminary submission classification; full source review pending. clawsweeper:intake:needs-environment Preliminary submission classification; full source review pending. clawsweeper:intake:needs-repro Preliminary submission classification; full source review pending. P1 High-priority user-facing bug, regression, or broken workflow. merge-risk: 🚨 automation 🚨 May affect CI, automerge, proof capture, label sync, or maintainer automation. merge-risk: 🚨 compatibility 🚨 May break existing users, config, migrations, defaults, or upgrade paths. merge-risk: 🚨 security-boundary 🚨 May affect sandboxing, authorization, credentials, or sensitive data. rating: 🦪 silver shellfish Thin PR readiness signal; proof, validation, or implementation needs work. status: 📣 needs proof The PR needs real behavior proof before ClawSweeper can clear the contributor ask. and removed clawsweeper:intake:bug Preliminary submission classification; full source review pending. clawsweeper:intake:needs-environment Preliminary submission classification; full source review pending. clawsweeper:intake:needs-repro Preliminary submission classification; full source review pending. labels Oct 16, 2026
@clawsweeper

clawsweeper Bot commented Oct 16, 2026 •

Copy link
Copy Markdown
Contributor

Codex review: needs maintainer review before merge.

What this changes

This PR prepares web-search policy in core and binds its use to current native-model and requester authority.

Example: Requester ID native-search-requester-late-requester-id-created is created after asynchronous admission.

  • Before: The absent-ID snapshot could permit a native request using the earlier search allowance.
  • After: The synchronous source assertion rejects the operation before any native thread or turn write.

Review scores

Measure Result What it means
Overall readiness 🐚 platinum hermit (4/6) The production-owner and physical-transport controls directly cover the authority repair, with no remaining finding; repository CI remains a separate landing gate.
Proof confidence 🐚 platinum hermit (4/6) Sufficient (terminal): The maintainer-supplied recording JSON-RPC proof exercises real core preparation, persisted requester mutations, Codex lifecycle admission, and the real transport client against a synthetic native server: the unchanged case completes with two writes and cached search, while all eight changed-model/requester cases reject with zero native writes, including changes after asynchronous admission; held-publication and cold-compaction controls support the shared-owner correction.
Patch quality 🐚 platinum hermit (4/6) No actionable review findings were identified.

Product

Kind: Bug fix · Worth it: Yes · Fix scope: Complete
User problem: A Codex turn can fail during policy lookup or dispatch hosted search using policy prepared for an outdated model or requester.
Reason: The maintainer-approved prepared-data design closes a concrete authority gap without new configuration, capability versions, or persisted formats.

Merge readiness

✅ Ready for maintainer review

The session-ID P1 and prior security hold are cleared at the reviewed head; no remaining introduced defect was found.

Priority: P1
Reviewed head: 2d00df6de14265b781d878ee14e37451e6e0b845

Before merge

None.

Findings

None.

Agent review details

How this fits together

Core prepares policy from session metadata and model identity, then Codex validates those facts through its existing lifecycle and native JSON-RPC write admission.

flowchart LR
  A[Agent attempt] --> B[Core policy preparation]
  C[Session worker and publications] --> B
  B --> D[Prepared model and requester facts]
  D --> E[Codex native policy owner]
  C --> E
  E --> F[Synchronous write assertion]
  F --> G[Native JSON RPC transport]
Loading

Technical review

Best possible solution:

Keep prepared policy as attempt data and enforce its model, requester, and ID-selection bindings through the existing native-write owner.

Do we have a high-confidence way to reproduce the issue?

Current-main source lacks the prepared model/requester binding, while the supplied native-boundary controls demonstrate the stale-authority failure on earlier heads; this read-only review did not rerun them.

Is this the best way to solve the issue?

The repair uses existing policy, publication, and native-admission owners, removes the asynchronous-only ID path, and preserves the accepted fallback scope.

AGENTS.md: found and applied where relevant.

Codex review notes: model internal, reasoning medium; reviewed against c51d21c0d73e.

Provenance checked

Testing

Proof path: in-process harness.

Security

None.

Evidence

What I checked:

PR surface

Source +434, Tests +750, Docs +18. Total +1202 across 31 files. Added test files: 2.

View PR surface stats
Area Files Added Removed Net
Source 18 527 93 +434
Tests 12 759 9 +750
Docs 1 18 0 +18
Config 0 0 0 0
Generated 0 0 0 0
Other 0 0 0 0
Total 31 1304 102 +1202

Labels

Label changes:

  • add rating: 🐚 platinum hermit: Overall readiness is 🐚 platinum hermit; proof is 🐚 platinum hermit and patch quality is 🐚 platinum hermit. Replaced prior rating: 🧂 unranked krab.
  • add status: 👀 ready for maintainer look: ClawSweeper has no concrete contributor-facing blocker left for this PR.
  • remove rating: 🧂 unranked krab: Current PR rating is rating: 🐚 platinum hermit, so this older rating label is no longer current.
  • remove merge-risk: 🚨 security-boundary: Current PR review merge-risk labels are merge-risk: 🚨 compatibility.
  • remove status: ⏳ waiting on author: Current PR status label is status: 👀 ready for maintainer look.

Label justifications:

  • P1: The remaining repair prevents stale requester or model policy from reaching native Codex dispatch.
  • merge-risk: 🚨 compatibility: The exported currentness helper gains ID selection and attempt parameters gain optional prepared data; the maintainer-approved additive contract preserves existing key-only and two-boolean callers.
  • rating: 🐚 platinum hermit: Overall readiness is 🐚 platinum hermit; proof is 🐚 platinum hermit and patch quality is 🐚 platinum hermit. Replaced prior rating: 🧂 unranked krab.
  • status: 👀 ready for maintainer look: ClawSweeper has no concrete contributor-facing blocker left for this PR.
  • proof: sufficient: Contributor real behavior proof is sufficient.

Rating scale

6/6 🦀 challenger crab · 5/6 🦞 diamond lobster · 4/6 🐚 platinum hermit · 3/6 🦐 gold shrimp · 2/6 🦪 silver shellfish · 1/6 🧂 unranked krab. Overall follows the weaker of proof and patch quality; ✨ marks media proof (a screenshot, video, or linked artifact) that directly shows the changed behavior.

Workflow

ClawSweeper edits this one comment on every review. Comment @clawsweeper re-review for a fresh review only. Repair and merge execution lanes are retired.

History

Review history (13 earlier review cycles; latest 8 shown)
  • reviewed 2026-10-17T07:36:08.381Z sha 85a500e :: needs changes before merge. :: [P2] Accept version-2 hosts in the projection SDK helpers | [P2] Complete the version-2 migration of Codex test consumers | [P2] Preserve the native-compaction fixture's version-1 projection
  • reviewed 2026-10-17T07:43:25.355Z sha 85a500e :: needs changes before merge. :: [P2] Accept version-2 hosts in both projection SDK helpers | [P2] Complete the version-2 migration of Codex registration tests | [P2] Preserve the native-compaction fixture's version-1 projection
  • reviewed 2026-10-17T09:23:26.441Z sha 99a0faa :: needs changes before merge. :: [P2] Supply version-2 authority to the remaining registration fixture
  • reviewed 2026-10-18T21:29:45.467Z sha 983fac8 :: needs real behavior proof before merge. :: [P1] Bind prepared search policy to the dispatched native model | [P2] Preserve separate execution and policy owners during compaction
  • reviewed 2026-10-19T00:25:26.881Z sha 10efe93 :: needs changes before merge. :: none
  • reviewed 2026-10-19T00:36:28.321Z sha 10efe93 :: needs changes before merge. :: none
  • reviewed 2026-10-19T01:17:38.780Z sha 8f4ef34 :: needs changes before merge. :: [P2] Route the native fixture through the canonical Codex test API
  • reviewed 2026-10-19T01:49:14.471Z sha b833540 :: blocked before merge. :: [P1] Retain session-ID selection through the physical native write

Reviewed October 19, 2026, 1:56 AM ET / 05:56 UTC (Revision 14).

@openclaw-barnacle openclaw-barnacle Bot removed the scripts Repository scripts label Oct 17, 2026
@steipete

Copy link
Copy Markdown
Contributor Author

@clawsweeper re-review

@clawsweeper

clawsweeper Bot commented Oct 17, 2026 •

Copy link
Copy Markdown
Contributor

🦞👀
Exact review queued.

Re-review progress:

@clawsweeper clawsweeper Bot added status: 📣 needs proof The PR needs real behavior proof before ClawSweeper can clear the contributor ask. and removed clawsweeper:intake:needs-repro Preliminary submission classification; full source review pending. labels Oct 18, 2026
Carry the exact model tuple and consumed requester policy/lineage facts with
core's optional prepared web-search result. Reject stale preparation through
the existing native execution-policy owner before thread or turn writes,
including ID lookups refreshed at physical native admission.

Skip unused search preparation during compaction, preserving the separate
execution and sandbox-policy owners. Keep existing SDK callers compatible.

Include the native requester-admission prerequisite from #176352. Recording
native-transport regressions cover unchanged policy, model changes, late
revocation/reassignment, revocation before capture, and missing-ID insertion.
@steipete

Copy link
Copy Markdown
Contributor Author

Addressed the findings in this review on the new head 10efe93144a47fbe52da0338557454791509ffef:

  • The prepared allowance now carries its exact provider/model tuple; Codex rejects a changed native tuple before applying it.
  • Compaction skips unused search preparation, preserving separate execution and sandbox-policy owners.
  • The stale-allowance security gap is closed at both intervals: core's original requester policy/lineage facts are compared before the native owner accepts its baseline, and retained/current checks gate native dispatch. ID lookups are also refreshed at physical write admission.
  • The PR body now includes the five-case real native-boundary table: unchanged runs with cached search, while changed model, late revocation, late reassignment, and revocation before native capture all reject with zero thread/turn writes. A sixth missing-ID insertion case covers the asynchronous lookup boundary.

All 12 individually invoked Node-runtime suites pass: selection (91), execution environment (22), base dynamic-tool-build (74), web-search dynamic-tool-build (18), sandbox dynamic-tool-build (6), native authority (13), provider review (14), capability store (10), prefix stability (5), host model execution (18), original deletion regression (2), and native boundary proof (6): 279 tests passed. Core and Codex source types, SDK surface/exports, Madge (zero cycles), touched lint/format, docs, and diff/line-cap checks pass.

Independent committed-branch autoreview is clean through P2: “patch is correct.”

@steipete

Copy link
Copy Markdown
Contributor Author

@clawsweeper re-review

@clawsweeper

clawsweeper Bot commented Oct 19, 2026 •

Copy link
Copy Markdown
Contributor

🦞👀
Exact review queued.

Re-review progress:

@chatgpt-codex-connector chatgpt-codex-connector Bot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

💡 Codex Review

Here are some automated review suggestions for this pull request.

Reviewed commit: 10efe93144

ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".

Preserve native source assertions and requester admission checks while adapting the prepared-policy regressions to current test fixtures. Keep the pre-existing unbound side-run fallback scoped to the separate F78 follow-up.
@steipete

Copy link
Copy Markdown
Contributor Author

@clawsweeper re-review

Merged current main into 8f4ef34e8b844e761b056e23b283473f2644ea51, preserving native source assertions and prepared-policy admission checks, and adapting the affected fixture tests. Independent Codex review of the merged candidate is scoped-clean through P2; touched formatting passes. Current-head CI is running.

The pre-existing /btw and missing-model supervision fallback is explicitly scoped to the separate F78 follow-up after this lands, as recorded in the inline disposition and known limitation. #176352 excluded re-resolving every ancestor policy edit.

@clawsweeper

clawsweeper Bot commented Oct 19, 2026 •

Copy link
Copy Markdown
Contributor

🦞👀
Exact review queued.

Re-review progress:

Load the native-search fixture through the existing lazy Codex test API and validate literal native binding fields against their actual contract. Fix the boundary and test-type failures from CI run 39184092677 without changing production policy behavior.
@steipete

Copy link
Copy Markdown
Contributor Author

@clawsweeper re-review

Current head: b833540890ecbaa06071a166ffa30b3d0c6b3518. This retains the reviewed merge of main and fixes only the two CI proof-fixture errors: use the existing lazy Codex test API and preserve literal binding types with satisfies.

The native PR worktree’s frozen install passed. All 20 boundary tests, all six recording-JSON-RPC native cases under Node, the exact failed root test-type config, targeted lint, and formatting pass. Independent Codex review is scoped-clean through P2. The native proof still completes allowed cached search with two writes and rejects all five stale model/requester cases with zero writes.

The unchanged /btw and missing-model supervision fallback remains the separate F78 follow-up, as explicitly dispositioned in the inline thread and known limitation.

@clawsweeper

clawsweeper Bot commented Oct 19, 2026 •

Copy link
Copy Markdown
Contributor

🦞👀
Exact review queued.

Re-review progress:

@chatgpt-codex-connector chatgpt-codex-connector Bot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

💡 Codex Review

Here are some automated review suggestions for this pull request.

Reviewed commit: b833540890

ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".

Reject native hosted-search writes when requester ID selection changes after policy preparation. Retain ID selection and absence in the existing session current-check owner, including pending worker publications, and remove the adapter's separate asynchronous ID path.
@steipete

Copy link
Copy Markdown
Contributor Author

@clawsweeper re-review

Please review exact head 97b231c1bed1ee13046e1645b41955a73674ebb8, which fixes the session-ID admission finding: #174774 (comment).

The existing session-currentness owner now retains ID selection, including absence and reassignment, through the synchronous assertion at the physical native write. It also covers ID-affecting commits pending host publication. The separate asynchronous-only ID path is removed.

Validation at this head: all 9 native-boundary cases pass, including late absent-to-present and reassignment controls; 19 session-owner tests and 103 Codex app-server tests pass. Core/source/test types, SDK surface/export synchronization and scoped source compatibility, lint/format, docs links, and zero-cycle checks pass. Independent committed-branch Codex review reports no findings through P2 and “patch is correct.” The existing helper's optional ID selector is additive; existing key-only and prepared-policy callers retain their source contract.

F78 (/btw and model-less supervision fallback) remains the separately tracked, already-dispositioned follow-up. Please reassess the previous session-ID security hold against this repair and its late-write/publication tests.

@clawsweeper

clawsweeper Bot commented Oct 19, 2026 •

Copy link
Copy Markdown
Contributor

🦞👀
Exact review queued.

Re-review progress:

Preserve the prepared model and requester binding, including retained session-ID write admission, while keeping the asynchronous recovery lookup from main.
Classify durable ID-selection publication guards as worker-compatible while
keeping memory-backed selection native. Preserve the existing live ID,
publication, physical-source, and requester checks at native writes.

Manual cold-transcript compaction no longer requires unrelated search
preparation. Cover the ID-selected path and inject conversation revocation
through the prepared restoration assertion without weakening its checks.
@steipete

Copy link
Copy Markdown
Contributor Author

@clawsweeper re-review

Please review exact head 2d00df6de14265b781d878ee14e37451e6e0b845 and assess the session-ID P1 repair described in #174774 (comment). ID selection, including absence and reassignment, is retained through the synchronous physical native-write assertion; pending ID-affecting publication also invalidates admission. Nine native-boundary cases pass, with zero native writes for all eight stale-authority cases.

The follow-up correction preserves memory-backed native classification while allowing durable ID-selected worker compaction. Cold storage passes 36/36 on both Node and Bun, session owners 29/29, and Codex app-server 103/103; types, SDK surface/exports, import cycles, touched checks, and independent full-branch review pass. The PR description contains the regression and exact-head proof. Please explicitly assess whether the repaired P1 and prior security hold are cleared. The already-dispositioned /btw and model-less supervision fallback remains the separate F78 follow-up.

@clawsweeper

clawsweeper Bot commented Oct 19, 2026 •

Copy link
Copy Markdown
Contributor

🦞👀
Exact review queued.

Re-review progress:

@steipete

Copy link
Copy Markdown
Contributor Author

Merged via explicitly authorized admin squash with attributed pre-existing CI failures.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

agents Agent runtime and tooling clawsweeper:intake:bug Preliminary submission classification; full source review pending. clawsweeper:intake:needs-environment Preliminary submission classification; full source review pending. clawsweeper:intake:needs-repro Preliminary submission classification; full source review pending. docs Improvements or additions to documentation extensions: codex merge-risk: 🚨 compatibility 🚨 May break existing users, config, migrations, defaults, or upgrade paths. merge-risk: 🚨 security-boundary 🚨 May affect sandboxing, authorization, credentials, or sensitive data. P1 High-priority user-facing bug, regression, or broken workflow. proof: sufficient ClawSweeper judged the real behavior proof convincing. rating: 🧂 unranked krab Not merge-ready due to missing proof or serious correctness/safety concerns. size: XL status: ⏳ waiting on author ClawSweeper has contributor-facing work open and is waiting for author action.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant