Repository navigation
fix(deploy): scope the transcription candidate gate to development - #9913
Merged
Merged
Conversation
The known-audio probe reaches the backend candidate over a Cloud Run tag URL, which is a run.app URL. Production deliberately serves no run.app URL (run.googleapis.com/default-url-disabled=true) and restricts ingress to internal-and-cloud-load-balancing, so a production tag resolves to no HTTPS endpoint. The deploy runner is GitHub-hosted and outside the VPC, so it could not reach such a URL even if one existed. The gate therefore cannot work in production by construction; it works in dev only because dev runs ingress `all` with the default URL enabled. The gate landed 2026-07-13, one day after the last successful production deploy (d40d43b, 2026-07-12), so it never executed against production until the Cloud Run binding fix (#9911) unblocked the deploy far enough to reach it. Run 29574215693 then failed at "Resolve transcription candidate URL": `Cloud Run tag 'stt-gate-29574215693-1' has no valid HTTPS URL`. Scope the tag and the four gate steps to development. This restores the 2026-07-12 production behavior and matches the step's own documented intent: the manual development deployment runs this probe as the auth and route dry run for production. Promotion steps keep no `if:`, so a skipped gate does not block traffic shifting. Verification: - Parsed the rendered workflow: all four gate steps carry the development condition, the --tag flag is development-gated, and the two promotion steps still carry no `if:` (a skipped step does not fail success()). - Mutation-checked the new guard: re-enabling the gate for production makes test_transcription_candidate_gate_is_development_only fail with "must be development-only; a production run cannot resolve a tag URL". - pytest tests/unit/{test_sync_two_lane,test_sync_ledger_fence_cutover, test_smoke_what_matters_now,test_resolve_cloud_run_tagged_url, test_verify_dev_backend_deployment,test_preflight_cloud_run_deploy}.py -> 86 passed. Production remains on the 2026-07-12 revision with 100% pinned traffic; the candidate revision from #9911 is Ready at 0% traffic.
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
With the Cloud Run binding fix (#9911) merged, the prod deploy got all the way through image build, all four Cloud Run services, GKE Helm, and the post-deploy runtime-env validation — then failed at
Resolve transcription candidate URL(run 29574215693):The known-audio probe reaches the candidate revision over a Cloud Run tag URL, which is a
run.appURL. Production deliberately has norun.appURL:run.googleapis.com/default-url-disabledtrueallinternal-and-cloud-load-balancingstatus.urlhttps://backend-…-uc.a.run.appSo a prod tag resolves to no HTTPS endpoint. This is not a transient failure — it is structural, and it would fail every prod deploy. Two independent blockers, in fact: even if the default URL were re-enabled, ingress is internal-only while the deploy runs on
ubuntu-latest-m, a GitHub-hosted runner outside the VPC.The gate works in dev only because dev is wide open.
Why it went unnoticed
The gate landed in d4252a6 on 2026-07-13 — one day after the last successful prod deploy (
d40d43be, 2026-07-12) and one day before the binding break (efca8b8, 2026-07-14). It has never executed against prod. The binding bug masked it; fixing that bug surfaced it.Change
Scope the
--tagflag and the four gate steps todevelopment. This restores the 2026-07-12 prod behavior and matches the step's own documented intent, already in the workflow:The gate keeps running on dev, where it works. The comment now records why prod is excluded, so this isn't silently re-enabled.
Promotion steps (
Verify validated revisions are still current,Shift Cloud Run traffic to validated revisions) keep noif:— a skipped step does not failsuccess(), so traffic promotion proceeds normally.Verification
--tagflag is development-gated; both promotion steps still carry noif:.Gate backend candidate on known audio must be development-only; a production run cannot resolve a tag URL, then restored. The guard catches the real regression rather than asserting a tautology.gcloud run services describe(default-url-disabled=true,status.urlempty, ingress internal-and-LB) and dev's (ingress: all, URL present).run.disableDefaultURI— the annotation is set on the service, deliberately.pytest tests/unit/{test_sync_two_lane,test_sync_ledger_fence_cutover,test_smoke_what_matters_now,test_resolve_cloud_run_tagged_url,test_verify_dev_backend_deployment,test_preflight_cloud_run_deploy}.py→ 86 passed.Prod is currently unchanged and safe: 100% traffic pinned to the 2026-07-12 revision, the #9911 candidate revision Ready at 0%, and the failed tag cleaned up.
Regression coverage
test_transcription_candidate_gate_is_development_onlypins all four gate steps and the tag flag as development-only, and asserts promotion does not depend on the gate. Mutation-verified above.Follow-up
This removes the pre-promotion STT gate from prod, which is worth naming explicitly: the pending
mainincludes a change defaulting free-plan live transcription to Parakeet, and that is exactly the class of regression this gate was built to catch. Recommend a dev deploy to exercise the gate against that change before promoting prod. Giving the probe a prod-viable route (VPC-connected runner, or a probe path that does not depend on a public revision URL) is separate work.Failure-Class: none