Repository navigation
fix(responses): keep search replay ID allocation linear - #7419
Conversation
|
No actionable comments were generated in the recent review. 🎉 ℹ️ Recent review info
📝 Walkthrough
Merge Risk: ⚪ Minimal · up to
|
|
✅ Deterministic PR hygiene checks passed. |
Ingwannu
left a comment
There was a problem hiding this comment.
Correctness approval at d2f23f1a4a5f7616e2efbb77a5f9a5d683db6d4d against dev 12025981e5a304cdb6b1b54f525ba8554f623977: request-local suffix cursors preserve the smallest free ID under the shared collision set, seeded IDs, alternate bases, duplicate cells, batching and original input positions.
Independent bounded Bun 1.4.3 regression: 112 pass / 0 fail across two files. Each workload ran alone under CPU/RAM/swap/process/time caps and fresh private HOME/CODEX_HOME/OPENCODEX_HOME/TMPDIR. Existing frozen dependency maps and lock matched; no live account/provider/client config was used. Current-head hosted ci/gates and the latest effective hygiene/enforce-target checks pass; older cancelled repetitions are superseded by later successful executions of those checks. Typecheck is evidenced by hosted gates, not a claimed new local compiler run. The changed contract and relevant negative controls were reviewed. This approval does not merge, release, certify unselected platforms, or authorize live operations.
Summary
Replaying several hosted search cells without usable IDs repeatedly rescanned already allocated suffixes. Keep a request-local next-suffix cursor for each base while retaining the request-wide collision set, so allocation grows linearly and still chooses the smallest available ID.
The regression coverage preserves seeded client IDs, alternate bases, duplicate-cell handling, batching order, and original input indices. The runtime contract is updated alongside the implementation.
Verification
bun scripts/test.ts --changed=12025981e5a304cdb6b1b54f525ba8554f623977 tests/web-search/web-search-sidecar-replay.test.ts tests/responses/responses-parser.test.ts— 112 passed, 0 failed, 307 assertions; exactly 2/2 selected test files.bun node_modules/typescript/bin/tsc --noEmit,bun scripts/structure-ssot.ts,bun scripts/privacy-scan.ts, andgit diff --checkpassed.The full local suite and live provider calls were not run. Local validation was bounded to the allocator and its existing parser consumers; the hosted CI on this exact head passed all required checks, including all four test shards. Platform-specific jobs outside this PR's CI policy were skipped.
Checklist