codex keeps its shell and apply_patch tools on the gpt-5.6 models - #24
Open
pedroapfilho wants to merge 1 commit into
Open
codex keeps its shell and apply_patch tools on the gpt-5.6 models#24pedroapfilho wants to merge 1 commit into
pedroapfilho wants to merge 1 commit into
Conversation
pedroapfilho
force-pushed
the
codex-developer-messages
branch
from
August 21, 2026 14:27
d07379b to
9d5e895
Compare
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.
The bug
Codex routed through tokenmaxx loses its shell and
apply_patchtools on the gpt-5.6 models. The model still answers, but it answers with text like this:Nothing in codex reports an error, so it reads like a codex or harness bug. It isn't. The proxy causes it.
adaptChatGptRequestlifts everysystemanddeveloperitem out ofinputand folds their text intoinstructions. The comment above it says codex requests already have that shape, so the rewrite is a no-op for them. That part is wrong: codex sends developer-role items ininputon every turn, and its tool contract rides in them. Once those items arrive flattened intoinstructions, the backend stops attaching the shell andapply_patchtools for the gpt-5.6 family. gpt-5.5 is unaffected.The rewrite has been in the proxy since 0.0.62 and worked fine for weeks, so this looks like a backend change on OpenAI's side that turned a tolerated shortcut into a broken one. In my session history, gpt-5.6-sol used tools in 36 of 41 sessions from Aug 17 to Aug 19, then 4 of 34 on Aug 20.
The fix
Lift only
system. Developer items stay ininput.That keeps the reason the function exists. The backend rejects
systemmessages from third-party harnesses with "System messages are not allowed", which is what broke pi, andmax_output_tokensis still dropped. Developer messages were never rejected, so they never needed lifting.How I verified it
Same machine, same account, same prompt (
codex exec "Run: echo hello"), counting whether the shell tool was actually called.I also ran 0.0.62 and 0.0.63 with gpt-5.6-sol and both failed 3/3, which is what ruled out a recent regression in this repo and pointed at the backend instead.
bun run checkpasses: typecheck, biome, 88 tests.The existing test for merging developer messages into instructions now covers
systeminstead, and there's a new test asserting developer items survive ininputwhile asystemitem in the same request still gets lifted.