Skip to content

Commit 74c146f

Browse files
anth-volkclaude
andcommitted
Wait for prod Cloud Run candidate readiness before smoke tests
The gunicorn early-bind entrypoint decouples revision readiness (port bound) from app readiness (country-package import finished, ~160s), so gcloud run deploy now returns while the app is still booting. The prod candidate job ran its smoke tests immediately after deploy and hit the importing instance, failing with read timeouts; the staging job was unaffected because it already gates test traffic on health_check.sh. Add the same readiness wait against the candidate tag URL before the smoke tests. Fixes #3731 Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
1 parent f648237 commit 74c146f

2 files changed

Lines changed: 3 additions & 0 deletions

File tree

.github/workflows/push.yml

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -517,6 +517,8 @@ jobs:
517517
echo "Cloud Run candidate URL: ${url}"
518518
env:
519519
CLOUD_RUN_TAG: ${{ steps.cloud_run.outputs.revision_tag }}
520+
- name: Wait for Cloud Run candidate health
521+
run: bash .github/scripts/health_check.sh "${{ steps.cloud_run_url.outputs.url }}/readiness-check"
520522
- name: Install Cloud Run smoke test dependencies
521523
run: pip install pytest httpx
522524
- name: Run Cloud Run candidate smoke tests
Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
Wait for the production Cloud Run candidate to pass its readiness check before running smoke tests, matching the staging job, so tests no longer race the app import that now happens after the port binds.

0 commit comments

Comments
 (0)