Repository navigation
Conversation
The retry fixture's two-second localhost deadline can expire while a busy test runner schedules its server thread, obscuring the intended 429/503-to-success assertion. Use the normal request deadline for this fixture only; the separate stalled-provider test continues to cover deadline cancellation. Co-Authored-By: Codegraff <blackfloofie@codegraff.com>
Keep the test-only timeout self-contained at fifteen seconds, so its intent is visible without resolving a production constant. The retry assertion and production behavior are unchanged. Co-Authored-By: Codegraff <blackfloofie@codegraff.com>
A loopback HEAD / probe can consume one of the three scripted mock connections, leaving the real embedding POST unanswered until its deadline. Ignore only that bodyless probe without advancing the 429/503/200 sequence, inject it in the test, and restore the original fixture deadline. Production retry behavior is unchanged. Co-Authored-By: Codegraff <blackfloofie@codegraff.com>
Merged
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.
What changed
The retry-only mock ignores up to eight complete
HEAD / HTTP/1.1probes without advancing its scripted HTTP 429 → 503 → 200 responses. The test injects one such probe and asserts it was ignored. The original two-second fixture deadline is restored. No production retry, timeout, transport, retrieval, or ranking code changes.Why
The intermittent
EmbeddingTimeoutwas not caused by a short deadline. A failing run showed the mock's third accepted request was a 61-byteHEAD / HTTP/1.1, not the third embedding POST. The three-connection mock exited onMissingContentLength; the real POST was left waiting for a response. Extending the deadline to 15 seconds and isolating I/O runtimes both failed because neither prevented an unrelated connection from consuming a scripted response. The mock now skips only the observed root-path HEAD probe, with a finite skip bound; malformed embedding POSTs still fail. The deterministic injected probe exercises that dispatch path.This test-only fix is separate from the watcher and installer PRs. It does not alter hosted Jina or the 4× ANN candidate pool.
Verification — exact head
d2cc4b5ac98e8bac2c060c328667bc225465cca3HEAD /probe and original two-second deadline.zig build --cache-dir .graff/verify/retry-head-probe-full-cache test --summary all— 33/33 steps succeeded; 1,621 tests passed and 13 skipped in this workspace.git diff --check— clean before commit.80771cdhead and is not acceptance evidence for this commit.This PR does not create a version, tag, signed artifact, or deployment. Release publication remains blocked separately by the PR-size preflight gate, live hosted embedding HTTP 530 responses, and macOS signing credentials.