ci: retry smoke tests to absorb Cloudflare edge propagation flakes - #132
Merged
Conversation
Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
|
🚀 Latest commit deployed to https://multistore-proxy-pr-132.development-seed.workers.dev
|
alukach
marked this pull request as ready for review
July 27, 2026 21:47
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 I'm changing
The smoke-test job fails intermittently on PR previews (e.g. run 30306016560 attempt 1, which passed unchanged on attempt 2). The failures are not ours: the 404 bodies are Cloudflare's
<title>Page not found</title>workers.dev placeholder, and they interleave with passing requests to the same host in the same second.A freshly deployed Worker propagates per edge machine, not per hostname. For a few seconds after
wrangler deploy, some requests tomultistore-proxy-pr-N.<subdomain>.workers.devland on a machine that does not have the script yet and get the placeholder 404; neighbouring requests succeed. In that runtest_assume_role_returns_credentialspassed at 21:16:13.3 while the fixture behindtest_assume_no_access_role_returns_credentials404'd at 21:16:13.4.The existing
Wait for deployment to be livegate (3 consecutive successful probes) cannot close this: it probes one URL and its probes may all be answered by machines that are already warm, so it reports live while others still 404.How I did it
.github/workflows/deploy.yml—Run smoke testsnow installspytest-rerunfailuresand runs with--reruns 4 --reruns-delay 5, giving ~20s of retry coverage for the propagation window. Comment above the step records why the deploy-side probe loop cannot solve this instead.Retries are scoped to the smoke job only;
tests/integration/inci.ymlis unchanged. A genuine regression fails all five attempts, so this hides nothing — it costs ~20s on a real failure.Test plan
deploy.ymlparses (yaml.safe_load)pytest-rerunfailuresretries fixture setup errors, not just test-body failures — the smoke suite's 404s surface as setup errors on theassume_no_accessfixture, so this was the load-bearing assumption. Verified with a throwaway suite whose fixture raises on its first two invocations:1 passed, 2 rerun.🤖 Generated with Claude Code