Conversation
|
✅ Deterministic PR hygiene checks passed. |
✅ READY
Review readiness checklist
✅ 4/4 boxes ticked. This pull request is already Ready for Review. |
|
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 (5)
📝 WalkthroughWalkthroughThe Responses handler now reports request-body acceptance after complete parsing. Aborted bodies return HTTP 499 without acceptance. Combo and policy-fallback executions deduplicate acceptance notifications. ChangesResponses body acceptance
Estimated code review effort: 3 (Moderate) | ~25 minutes Merge Risk: ⚪ Minimal · up to The PR bounds request-body reads and preserves cancellation handling without a supplied indication of a concrete current-head defect; no actionable merge-blocking risk remains after normal checks and review. Sequence Diagram(s)sequenceDiagram
participant Client
participant ResponsesRoute
participant handleResponses
participant PolicyFallback
participant UpstreamTargets
Client->>ResponsesRoute: POST request body
ResponsesRoute->>handleResponses: provide onRequestBodyRead
handleResponses->>handleResponses: read and validate complete body
handleResponses-->>ResponsesRoute: invoke body-read callback
ResponsesRoute->>ResponsesRoute: disable request timeout
handleResponses->>PolicyFallback: dispatch request
PolicyFallback->>UpstreamTargets: execute initial attempt
PolicyFallback->>UpstreamTargets: execute fallback retry
PolicyFallback-->>ResponsesRoute: return final response
Possibly related PRs
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 |
lidge-jun
left a comment
There was a problem hiding this comment.
[Repository bug audit · 2026-08-14]
The lifecycle change is coherent: keep Bun's inbound timeout active until the complete request body is accepted, make the transition one-shot across combo/policy retries, and classify an aborted pending body as the existing 499 cancellation path. The focused tests cover partial-body, abort, combo, and fallback behavior.
This PR is currently not mergeable against dev. Rebase, resolve the server/request-path overlap without moving the callback earlier than successful body parsing, then rerun server-auth, routing-policy-fallback, typecheck, and exact-head Cross-platform CI.
|
Cherry-picked onto dev as part of the bug resolution campaign (commit-and-merge loop). Changes verified with typecheck and focused tests. |
Summary
/v1/responsesbody is still arriving, and disable it only after the complete body is accepted for dispatch.499 client_cancelledresponse instead of a generic malformed-request response.Verification
devatc6688c79ff58ca4f4a6502f6e6a4228124b45047; exact head:e26cbb415b70d2ee372d10103a6585024e557673.bun test --isolate tests/server-auth.test.ts— 78 pass.bun test --isolate tests/routing-policy-fallback.test.ts— 5 pass.bun run typecheckpassed on both runtimes.bun run privacy:scanandgit diff --checkpassed.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