fix(codex): bound warmup response bodies - #1725
Conversation
|
✅ Deterministic PR hygiene checks passed. |
|
No actionable comments were generated in the recent review. 🎉 ℹ️ Recent review info⚙️ Run configurationConfiguration used: Path: .coderabbit.yaml Review profile: ASSERTIVE Plan: Pro Plus Run ID: 📒 Files selected for processing (3)
📝 WalkthroughWalkthroughWarmup HTTP error bodies now use bounded reads, and SSE responses have a 1 MiB limit. Oversized streams return ChangesWarmup response safety
Estimated code review effort: 3 (Moderate) | ~20 minutes Merge Risk: ⚪ Minimal · up to The PR bounds warmup response bodies and keeps cancellation non-blocking; no actionable merge-blocking risk remains after normal checks and review. Possibly related PRs
Suggested labels: Suggested reviewers: 🚥 Pre-merge checks | ✅ 5✅ Passed checks (5 passed)
✨ Finishing Touches🧪 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 |
⏳ DRAFT
What to do
Review readiness checklist
2/4 boxes ticked. This PR stays in draft until every box above is ticked. Hygiene✅ Deterministic PR hygiene checks passed. |
|
@coderabbitai review Please review exact head |
|
✅ Action performedReview finished.
|
|
Solid hardening fix — bounding the warmup drain and reusing readBoundedResponseBody with the shared abort signal is exactly the shape we want, and the boundary/cancel tests are thorough. Keeping as draft pending the contributor readiness checklist and a maintainer-triggered full CI run (fork PRs can't start repository CI). Flagging for maintainer CI. |
Summary
stream_too_largefailure above the limit.Exact base:
cce29958ae62fc07f64631226eb8485584496b71Exact head:
9589a7a0b7d177ee941f25cfa79ed9c23be901efVerification
bun test --isolate --timeout 60000 tests/bounded-body.test.ts tests/cancel-body-on-abort.test.ts tests/codex-warmup.test.ts tests/warmup.test.ts— 52 pass, 0 fail, 131 assertions.bun run typecheck— pass on both runtimes.bun run privacy:scan— pass on both runtimes.git diff --check— clean.fcb01e0c-dffd-4771-9718-73eb65a5a3ba— CLEAN, complete coverage, snapshot digest0ec14ede02b9fd4c0dbff9faaadd3eab8b2ec2478bbde80cf93309f385502515.fbe53146e7d9934d4a65a28c34c7448e40701a5d.Checklist
Review readiness checklist
This PR stays in draft until every box below is ticked. Tick all four boxes once the requirements are met:
All CI tests are green on my local testing.
I pushed my PR to the latest dev commit.
I resolved all correct Codex and CodeRabbit findings.
My PR is ready for review.
Summary by CodeRabbit
Bug Fixes
stream_too_largeerror.Tests