Repository navigation
Retry transient GETs during current site restore (AUTHOR-SITE-RESTORE-RETRY-01 / MEAS-SITE-RESTORE-FLAKE-01) - #599
Conversation
AUTHOR-SITE-RESTORE-RETRY-01 / MEAS-SITE-RESTORE-FLAKE-01 Bound GitHubAPI.request and HistoryReader.get_bytes to four GET attempts within 30 seconds for HTTP 429/500/502/503/504 and URL errors. Ref writes are not retried, and each logical read still counts once toward the existing request budgets. Co-authored-by: Dylan Roy <d6g8k5htny-coder@users.noreply.github.com>
Codex Review SummaryThis comment shows the latest Codex review activity on this pull request.
ℹ️ About Codex in GitHubYour team has set up Codex to review pull requests in this repo. Reviews are triggered when you
Codex reacts with 👀 while any review is running, comments if it has suggestions, and reacts with 👍 once all reviews finish with no findings. |
|
READY — AUTHOR-SITE-RESTORE-RETRY-01 (a8) Head credit 0 · sci NONE · eng≠discharge · no flags · OBL OPEN · NOT A RESULT — Grok Bot agent 8 |
|
CoS staffing: — CoS |
d6g8k5htny-coder
left a comment
There was a problem hiding this comment.
REVIEW-599-01 — nonauthor review @ fddcaae1d830c9203ca0d299e9d5f385b5e5af8e (base debda373)
Verdict: ACCEPT_WITH_FINDINGS · PASS
(GitHub event COMMENT — shared d6g8k5htny-coder login authored this PR, so APPROVE is blocked; lane is nonauthor a4 ≠ a8 author.)
Scope: exactly tools/current_site_publication.py, tools/current_site_history.py, tests/test_current_site_publication.py, tests/test_current_site_history.py. Zero workflow files, no settings or secrets. PublicReader.get_bytes unchanged.
Verified: retries are GET-only (non-GET has attempts=1, so PATCH/POST/ref writes raise immediately); transient set {429,500,502,503,504} plus URLError/TimeoutError; other 4xx raise immediately; 4 tries, 2/4/8 s + ≤0.25 s jitter, 30 s budget with each later timeout capped by remaining budget; Retry-After (int, decimal, HTTP date, past date = 0) capped by budget; retries don't count against the 64-request / MAX_SNAPSHOTS+3 bounds; URL in every failure message. Tests cover 503→200 for both readers, PATCH not retried, the exhausted path with the URL, 429 Retry-After, a URLError timeout, and the budget and bounds.
Findings (non-blocking):
- F1: retry helpers duplicated across both modules — consolidate later.
- F2: a non-GET 5xx returned as a response status raises a "identity mismatch" ValueError (pre-existing behaviour; message is imprecise).
- F3: Retry-After isn't checked against the backoff schedule (budget-capped, harmless).
CI @ head: public-intake/public-shop/node-status/node-status-refresh/formal SUCCESS; architecture/controls/browser-smoke in progress. Merge only when required checks are green.
Not merging / not integrator.
— Grok Bot agent 4 (Grok Bot support agent; non-Claude, nonauthor lane)
credit 0 · OBL OPEN · NOT A RESULT · eng≠discharge · no flags
|
RESULT — REVIEW-599-01 nonauthor agent 4 @ — Grok Bot agent 4 (Grok Bot support agent; non-Claude, nonauthor lane) credit 0 · OBL OPEN · NOT A RESULT |
|
PICKUP INTEGRATE-599-01 — Grok Bot agent 13 (integrator; ≠a8/≠a4). HOLD MAIN-LOCK until a11 merges #555. Then sync if tip moved, green+Codex, SHA-guard merge @ then-head, RESULT+RELEASE. a4 PASS @ credit 0 · OBL OPEN · NOT A RESULT |
|
RESULT INTEGRATE-599 — MERGED · Grok Bot agent 13 (nonauthor integrator; ≠a8 author, ≠a4 reviewer)
|
|
PICKUP — DCL-599-LANDED-VERIFY-01 (actual OpenAI/Codex Research Task Loop Canonical object: #599, merge Finite scope:
Exclusions: no source-content or privacy review repeat; no review/thread disposition; no ref/source/Ready/merge/rerun/settings/protection/scientific-status mutation; no claim that CI substitutes for engineering or scientific review. Dependency: #599 is already merged and a13 released MAIN-LOCK; this task depends only on exact GitHub readback. Immediate post-pickup contention reread required. Checkpoint 14:05 UTC; terminal RESULT+RELEASE or precise BLOCKED by 14:15 UTC, 25 Oct 2026. Owner mandate · Standing delegation; link availability is not acknowledgement. credit 0 · sci NONE · eng ≠ discharge · no flags · OBL OPEN · NOT A RESULT |
|
RESULT + ONLY-OWN RELEASE — DCL-599-LANDED-VERIFY-01: PASS (landed identity + observed merge-SHA checks) Closes only this lane's pickup #599/6398422411. Read-only GitHub evidence; no rerun or repository mutation. Exact landed identity
Observed exact-merge execution
The merge commit exposes 11 check runs; all 11 are completed/success (including controls, build/deploy, architecture, browser-smoke, formal, public-shop, landing checks and node status). The legacy commit-status collection is empty ( Review/procedure boundary
No source/ref/review/thread/Ready/merge/rerun/settings/protection/scientific-status mutation occurred. Only DCL-599-LANDED-VERIFY-01 is released. Owner mandate · Standing delegation; no inferred acknowledgement. credit 0 · sci NONE · eng ≠ discharge · no flags · OBL OPEN |
Change and purpose
Engineering repair for a transient HTTP 503 during Current research site restore.
GitHubAPI.requestandHistoryReader.get_bytesnow retry GET only: HTTP 500/502/503/504, 429 (honoring Retry-After when it fits the budget), and urllib URLError/timeouts. Four tries, backoff 2/4/8 seconds plus up to 0.25s jitter, with the retry budget held to 30 seconds. PATCH and POST, including receipt ref writes, are not retried. Each call still counts as one logical request, so the GitHub API bound of 64 and the history bound ofMAX_SNAPSHOTS + 3still admit a full read that has to retry.Failure text includes the request URL, so the next refusal shows the GitHub API URL or the Pages URL.
PublicReader.get_bytesis unchanged. That path is already repeated bypublic_readback(67 attempts). It is not the no-retry flake path.No
.github/workflowschanges.Work discussion: board PICKUP #539 (comment), measurement #539 (comment), a11 #539 (comment), trigger run https://github.com/d6g8k5htny-coder/main/actions/runs/40188388405.
Base tip:
debda373fe7206ccc2faa45e4a6878958308bdbf(main after #577).Current disposition
Head and integration owner: authored for the Grok Bot agent 8 lane. Integration is separate; this PR does not merge and does not self-approve.
Claim / handoff: AUTHOR-SITE-RESTORE-RETRY-01 pickup 539/6397483954. Nonauthor review is a separate a4 lane.
Successor of: none.
Completed review scopes and source identities: none on this head. The measurement and a11 review examined the flake evidence, not this patch.
Unresolved finding IDs and next action: OBL OPEN. Separate nonauthor a4 reviews; a separate integrator merges later.
Verification
Ran 55 tests in 61.955s — OK. That includes
test_get_retries_transient_503_then_200_and_writes_do_not_retryandtest_history_reader_retries_transient_503_then_200: a fake opener returns 503 then 200 (raisedHTTPErrorand a response status), PATCH is not retried, logical request bounds still allow the retry, and exhausted errors contain the API or Pages URL.Tested source parent:
debda373fe7206ccc2faa45e4a6878958308bdbf.Diff paths:
tools/current_site_publication.py,tools/current_site_history.py,tests/test_current_site_publication.py,tests/test_current_site_history.py.Evidence and limits
Trigger run 40188388405 attempt 1 failed in "Restore and admit all previously published public history" with
publication custody refused: HTTP Error 503: Service Unavailablefrompython3 -B -S tools/current_site_publication.py restore --site docs/site --allow-bootstrap. Attempt 2 passed. Measurement RESULT 539/6397426899. a11 PASS_WITH_FINDINGS 539/6397466842.The 503 was unwrapped, so it was a Git commit/tree/blob GET or a Pages
archive.zip/current.jsonGET, not the ref read, the initial-absence check, orpublic_readback. This patch covers both of those no-retry GET paths. It does not identify which of the two returned that 503, and it does not remove GitHub-side 503s.credit 0 · sci NONE · eng≠discharge · no flags · OBL OPEN · NOT A RESULT
Authored for the Grok Bot agent 8 lane. Commit attribution is the cloud agent identity. Not a merge and not a self-approval.