fix: add retry logic to integration test for httpbin.org flakiness#96
Merged
Conversation
added 4 commits
June 4, 2026 08:53
httpbin.org occasionally returns 503, causing CI to fail on transient errors. Retry up to 3 times with 5s delay between attempts.
httpbin.org has been unreliably returning 503, causing persistent CI failures. Replace it with mccutchen/go-httpbin running locally in the test compose stack. Changes: - Add compose-override.yml with go-httpbin container aliased as httpbin.org - Add GATEWAY_INSECURE_UPSTREAM env var to forward upstream as HTTP (local echo server doesn't need TLS) - Remove retry logic (no longer needed with local server) - run.sh uses -f compose-override.yml to merge with generated compose
go-httpbin image is a scratch/minimal image without wget or nc, so healthcheck doesn't work. Use service_started instead — the Go server starts instantly anyway. Also use command flag to set port 80.
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.
Problem
The integration test calls httpbin.org to verify credential injection. httpbin.org occasionally returns 503, causing CI to fail on transient errors unrelated to our code.
This has caused false failures on multiple PRs (#94, #95).
Fix
Add a retry loop (3 attempts, 5s delay) around the curl call. If the first attempt gets a non-matching response (e.g. 503), it retries before declaring failure.
Changes
tests/integration/sandbox/run.sh: wrap credential injection check in retry loop