Repository navigation
Conversation
…playable refusal, not home_unreachable A post-dispatch transport failure or a post-resolve abort cannot prove the turn never reached Home. Labelling them home_unreachable authorized a second dispatch of a possibly-running turn via GOAT local fallback or a combo hop. Answer the shared replay-refusal contract instead (429, x-should-retry: false, upstream_reset_replay_refused / upstream_closed_before_response, in-process markers). Clean refusals keep home_unreachable: preflight failures, credential-free auth deadlines, and refused connections with an untouched body.
…and sync refusal docs Post-dispatch failures that leave the upstream response undeliverable (response headers/body over the relay limit) now settle as a non-replayable 429 upstream_response_refused instead of a retryable 502 that would re-dispatch an already-run turn. A refused connection stays home_unreachable whenever the request provably never left the relay, regardless of body consumption, while the resendable check only gates the relay-internal resend. Docs and the refusal-code contract list the new code in en/es.
Contributor
|
Important Draft PR not reviewedDraft PRs are not automatically reviewed by default.
To automatically review draft PRs, update your CodeRabbit configuration: reviews:
auto_review:
drafts: true
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. |
Contributor
|
✅ Deterministic PR hygiene checks passed. |
This branch has not been deployed
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.
Summary
A Link failure after dispatch could become a generic gateway error, allowing retries, key rotation or a combo hop to send the same request again. Native POST response-header deadlines had the same problem after the upstream had received the body.
x-should-retry: falsebefore waiting for or classifying the body, including delayed HTTP bodies. Keep proxy-owned quota attribution separate from that general no-retry instruction.Verification
Final local integration:
723d34c2a6706cc054d3af6a32c1a899aaab6728, withdevcommit3ef14ad572f3682b01143018c5efb6cc1f3180f6. The merge had no conflicts or manual production changes. Three additional regressions cover composition with offline wait.Bun 1.4.4, repository-root runner, official preload and semantic test lock, one worker. Commands used the prefix
bun --no-env-file --no-install scripts/test.tsand suffix--parallel=1 --timeout 30000 --no-env-file --no-install:./tests/responses/responses-offline-resend.test.ts ./tests/responses/responses-combo-unavailable-cause.test.ts ./tests/server/fetch-header-timeout.test.ts./tests/lib/upstream-retry.test.ts ./tests/providers/upstream-transient-retry.test.ts./tests/server/replay-refusal-parity.test.ts --test-name-pattern 'serialized relay|ordinary quota|no-retry quota'./tests/test-layout.test.ts ./tests/test-layout-tooling.test.ts ./tests/ci-workflows/file-size-ratchet.test.ts --test-name-pattern 'membership oracle|tests/ layout|file-size ratchet'./tests/server/native-remote-local-fallback.test.ts, in the explicit credential-free proof environmentTotal: 237 passed / 0 failed / 1,416 assertions, with no timeout in the final integration runs.
bun check --no-script --noEmitchecked 2,554 files;bun run structure:checkandbun run privacy:scanpassed.The native proof uses actual handlers/adapters and loopback TCP. It observed:
The 18-case proof is opt-in (
OCX_NATIVE_PROOF_CREDENTIAL_FREE=1plus an isolatedOCX_NATIVE_PROOF_ROOTand process-local homes/TEMP/cache, with credential variables absent). Its preflight checks the repository preload, guard and path containment before importing the product graph; every case drained owned work. Default CI skips this proof; three new helper regressions in the existing test file run normally. Tool continuity may reconstruct the prefix rather than forward the original response ID.The original header-timeout case failed before the fix; disabling the new refusal branch also made the focused regression fail, then restoring it returned the helper file to green. Independent review covered the runtime change at
2c5072e59c7826e3928b44ef265657ec0080229c; the subsequent merge required no manual production edits, retained the reviewed header-deadline helper bytes, and received the integration checks above.Full/import-connected local validation was not completed because the broader selection exceeded the shared Windows host's execution budget. This uses the documented resource exception; the final focused coverage above is the local claim, with broader coverage left to automatic PR CI. Official SDK execution, documentation build and real two-device Link enrollment/operation were not run. Hosted CI remains a separate posted-head check.
Checklist
The security checkbox records implementation review; explicit maintainer security review remains required before merge.