Repository navigation
Stop requiring an exact item type nobody has verified - #32
Merged
Merged
Conversation
The guard matched the search item type against an anchored list containing `web_search`. This repository's own test asserts Codex emits `web_search_call`. Under that guard a real search does not merely go uncounted, it terminates the run as a tool attempt: the allowance was written so narrowly that it excluded the thing it exists to permit. The deeper fault is that the design needed the exact vocabulary and nobody had it. Matching is now on a substring, and more importantly the run reports what it saw rather than being assumed: - every distinct item and event kind the run emitted - what stopped the run, named, when the guard stopped it - what Codex wrote on stderr All three are kept for a researched run that recorded no search, and the phone prints them under the research trace. Four consecutive root causes for this were inferred from silence and at least two were wrong. One real run now answers the question instead. Co-Authored-By: Claude Opus 5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01FxxEQsJEXq9hZmjpNH5PxY
|
The latest updates on your projects. Learn more about Vercel for GitHub.
|
This branch was successfully deployed
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.
A contradiction inside this repository
sandbox/worker.mjspermitted a search only when the item type matched^(web_search|web_search_request|web_fetch|browser_search)$.tests/core/research.test.tsasserts Codex emitsweb_search_call.Anchored,
web_search_calldoes not match. So under the guard onmainright now, a real search does not merely go uncounted — it terminates the run as a tool attempt. The allowance was written so narrowly that it excluded the thing it exists to permit. I wrote both files and never compared them.The deeper fault
The design required knowing Codex's exact event vocabulary, and I don't have it. Four consecutive root causes for this problem were inferred from silence and at least two were wrong. Continuing to guess is the actual bug.
So the run now reports rather than being assumed:
All three are retained when a researched run records no search, and the phone prints them under the research trace:
That is a diagnosis. Every previous answer was a guess.
Matching is now on a substring, so both spellings work, while
command_execution,apply_patch,mcp_tool_call,file_change,list_dir, and an unknown future tool all still terminate the run — verified by replay across 15 event classes.Tests
web_searchandweb_search_callare recognised;command_executionandapply_patchare not107 unit tests (106 pass / 1 Windows-only skip), mocked e2e, lint, build clean.
What I am claiming
Not that this fixes it. Only this: after deploying, one researched review will print what the run emitted and what stopped it, in Codex's own vocabulary. That is the evidence I have been missing for five rounds, and it ends the guessing either way.
Generated by Claude Code