Repository navigation
fix(openai-chat): bring openai-chat.ts back under its file-size cap - #5822
Conversation
#5804 left the adapter one line over its 822-line cap, failing the file-size ratchet on dev. The freeform-tool lookup it added now lives in serialized-tool-call-content.ts as freeformToolsByWireName(), beside the echo matching that uses it, and the repeated { name, namespace } shape is one FreeformToolIdentity type. No behavior change.
Codex Review SummaryThis comment shows the latest Codex review activity on this pull request.
ℹ️ About Codex in GitHubYour team has set up Codex to review pull requests in this repo. Reviews are triggered when you
Codex reacts with 👀 while any review is running, comments if it has suggestions, and reacts with 👍 once all reviews finish with no findings. |
|
Navigate logical layers of code changes, visualize relationships, and explore their blast radius. Note Currently processing new changes in this PR. This may take a few minutes, please wait... ⚙️ Run configurationConfiguration used: Repository: lidge-jun/opencodex/.coderabbit.yaml Review profile: ASSERTIVE Plan: Advanced Run ID: 📒 Files selected for processing (2)
✨ Finishing Touches📝 Generate docstrings
🧪 Generate unit tests (beta)
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
|
✅ Deterministic PR hygiene checks passed. |
Summary
devfailsfile-size ratchet: repository: #5804 leftsrc/adapters/openai-chat.tsat 823 lines against its 822-line cap, so every branch cut fromdevgoes red on that test. The cap only moves down, so this moves code instead of raising it.The freeform-tool lookup #5804 added is built by
freeformToolsByWireName()insrc/adapters/openai-chat/serialized-tool-call-content.ts, beside the echo matching that consumes it. The{ name, namespace }shape repeated four times across both files is now oneFreeformToolIdentitytype.openai-chat.tsis back to 822 lines. Behavior is unchanged.Verification
bun test tests/ci-workflows/file-size-ratchet.test.tsplus every openai-chat, chat tool-call, chat-compat, and MiMo test file (29 files): 462 pass, 0 fail.tests/adapters/openai/openai-chat-serialized-tool-call-content.test.tsgains a case forfreeformToolsByWireName(): only freeform tools are kept, keyed by wire name, with the declared name and namespace (42 pass).bun x tsc --noEmit,bun run structure:check,bun run privacy:scan: pass.devafter merge.Checklist