Repository navigation
fix(reef): add timeout and bounded JSON reads to relay transport - #108333
Conversation
|
Codex review: needs real behavior proof before merge. Reviewed July 18, 2026, 7:52 AM ET / 11:52 UTC. Summary PR surface: Source +19, Tests +80. Total +99 across 2 files. Reproducibility: yes. in source: Review metrics: 1 noteworthy metric.
Merge readiness Overall follows the weaker of proof and patch quality, so missing proof can cap an otherwise strong patch. Rank-up moves:
Proof guidance:
Risk before merge
Maintainer options:
Next step before merge
Security Review detailsBest possible solution: Keep the shared bounded JSON reader and land the composed timeout after the contributor posts redacted final-head terminal or live output that exercises a response which sends headers and then stops producing body bytes. Do we have a high-confidence way to reproduce the issue? Yes in source: Is this the best way to solve the issue? Yes for the code shape: composing the existing timeout helper with the caller signal at the transport request boundary preserves the shared bounded JSON-reader path. The remaining requirement is evidence that the post-header body-stall path works on the final head in a real run. AGENTS.md: found and applied where relevant. Codex review notes: model internal, reasoning high; reviewed against f98bcb7fa73c. Label changesLabel changes:
Label justifications:
Evidence reviewedPR surface: Source +19, Tests +80. Total +99 across 2 files. View PR surface stats
What I checked:
Likely related people:
What the crustacean ranks mean
Shiny media proof means a screenshot, video, or linked artifact directly shows the changed behavior. Runtime, network, CSP, and security claims still need visible diagnostics. How this review workflow works
Review history (15 earlier review cycles; latest 8 shown)
|
a215c6e to
5d2038c
Compare
|
@clawsweeper re-review Both review asks are addressed on the new head Branch is now Reef-only. The unrelated daemon commit ( Exact-head controlled-relay proof. Real loopback HTTP+WebSocket relay (no fetch mocks; real This covers the four requested behaviors: stalled pre-header request aborts at the 15 s deadline (surfaces as Focused tests on the same head: |
|
🦞👀 Command router queued. I will update this comment with the next step. |
|
Rebased onto current |
9dc07e5 to
ae0c6ae
Compare
|
Rebased onto current This should clear the stale |
PR Ready for Maintainer ReviewBranch has been cleaned up — only Reef transport timeout changes remain (no unrelated daemon files). All CI green. Evidence summary
@clawsweeper re-review |
|
@clawsweeper re-review Branch is reef-only with all CI green. Real behavior proof in PR body (stall-timeout + bounded JSON relay reads). Ready for re-review. |
|
🦞🧹 I asked ClawSweeper to review this item again. Re-review progress:
|
Co-authored-by: 陈宪彪0668000387 <[email protected]>
bb059df to
b94da60
Compare
Co-authored-by: 陈宪彪0668000387 <[email protected]>
|
Merged via squash.
|
What Problem This Solves
The Reef relay transport client (
extensions/reef/src/transport.ts) had no request deadline. A relay that stalls before headers or during a response body can pinReefInboxConnection.drain()and stop recovery.Why This Change Was Made
Bounded JSON reads already landed on
mainvia #106456. This PR adds the missing 15 s request deadline withbuildTimeoutAbortSignal, composes it with the inbox caller signal, and keeps it active through response-body consumption. Ordinary HTTP failures remain typedReefRelayErrors; a stalled success or error body preserves theTimeoutError.User Impact
TimeoutErrorat the 15 s deadline and triggers the existing reconnect path.Evidence
transport.timeout.test.tsandtransport.test.ts; targeted formatting clean. Run: https://github.com/openclaw/openclaw/actions/runs/29636735249b94da60a30be87353c30f08cb1a217932657a65a.