Repository navigation
fix(ci): sign the dev backend release probe for its Firebase project - #12264
Merged
Git-on-my-level merged 1 commit intoAug 26, 2026
Merged
Conversation
The known-audio gate authenticates against the production Firebase project (based-hardware) because the development backend verifies user tokens there. Since 224b2c5 split project_id from firebase_auth_project_id, the gate corrected the token *audience* but kept signing with the development deploy identity, which Identity Toolkit will not accept for another project. Every manual development backend deploy has failed at custom_token_signing/permission_denied since then, so development has been silently refusing new deploys: candidates were built --no-traffic and never promoted. BasedHardware#12019 plumbed an escape hatch, firebase_probe_signer_service_account, but the variable it reads has never been set and needs an IAM grant to be usable. Sign locally with the Firebase project's own key instead. That is what desktop_backend_auto_dev.yml already does for the identical project split, and what .github/AGENTS.md prescribes: stage the environment-owned GCP_SERVICE_ACCOUNT in a mode-0600 runner file, let the token minter reject signer-project drift before the key is used, and delete the key after the probe. No IAM change is required. The named-signer input stays available and is only consulted when no credential is supplied. sync_ledger_fence_cutover.yml carries the same split in its development lane and is wired the same way; its production lane deploys into based-hardware and keeps signing with its active identity. Co-Authored-By: Claude Fable 5 <[email protected]>
Git-on-my-level
added a commit
that referenced
this pull request
Aug 27, 2026
…12274) The manual development backend deploy ran its post-promotion smoke against https://api.omi.dev, which has never resolved: the omi.dev zone exists but the api record is NXDOMAIN, so smoke_what_matters_now.py could not reach anything and failed with "could not reach the deployed backend". That failed the deploy after traffic had already shifted and triggered the traffic restore, rolling the promotion back. Development's real public API host is api.omiapi.com, which matches the rest of the development domain family (parakeet.omiapi.com, nllb.omiapi.com, pusher.omiapi.com in backend/deploy/runtime_env/dev.overlay.yaml) exactly as production uses the omi.me family. It serves /ready 200 today. Making api.omi.dev real was rejected: the codebase already uses it as the canonical fake hostname in mobile production-routing tests, so giving it a live record would undermine those fixtures. This defect was introduced by 933fdf7 on the same day as the probe-signer defect fixed in #12264, and stayed invisible because the probe failed first. Run 33008079463 is the first development deploy to reach this step. The step is guarded to the manual development lane; the production smoke keeps its own api.omi.me path untouched. Co-authored-by: Claude Fable 5 <[email protected]>
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.
Failure-Class: FC-release-probe-signer-identity
Product invariants affected
This change does not move any Firebase or Firestore project.
firebase_auth_project_idstays
based-hardwareon every lane; only how the probe signs changes.What is broken
Every manual development backend deploy fails deterministically at the
Gate backend candidate on known audiostep:Reproduced today on runs 32992789266 and 32994463647 (both
af8a490afc), and at07:29:24Z on the unrelated commit
d5c6d75— so this is not a regression fromtoday's merges.
The blast radius is quiet and bad: candidate revisions are deployed
--no-traffic,the gate fails before promotion, the tag is torn down, and dev keeps serving the old
revision. Development has been silently refusing new deploys — dev is still on
0300eb2, which is why PR #12258's rate-limit change never reached it.Root cause
firebase_auth_project_id: based-hardwareis correct and deliberate: thedevelopment backend verifies user tokens against the production Firebase project.
firebase_release_probe_token.pysays so, and_validate_firebase_id_token_claimsenforces
aud == based-hardware. So this is not a wrong-project string to swap.The defect is the signer, introduced by 224b2c5 ("fix(dev): harden realtime
provider proof", 2026-07-14). That commit split the single
project_idinput intoproject_id(Secret Manager + deploy identity) andfirebase_auth_project_id(token audience). Before the split both were
based-hardware-dev, so the deployidentity signed for its own project. After the split the audience was corrected
but the signer was not: the probe still calls IAM
signJwtas thebased-hardware-devdeploy identity, and Identity Toolkit only accepts a customtoken whose signer is authorized for the Firebase project — hence 403
permission_deniedatcustom_token_signing. 404eb82 carried it verbatim intothe shared composite action.
#12019 diagnosed this correctly and plumbed an escape hatch,
firebase_probe_signer_service_account←vars.FIREBASE_PROBE_SIGNER_SERVICE_ACCOUNT.That variable has never existed (it is absent from both repo variables and the
developmentenvironment), and using it would also require aroles/iam.serviceAccountTokenCreatorgrant. The hatch stayed empty and the lanestayed dead.
The fix
Adopt the resolution that already works for the identical split, one workflow over.
.github/workflows/desktop_backend_auto_dev.ymldeploys intobased-hardware-devwith
FIREBASE_AUTH_PROJECT_ID: based-hardwareand signs locally with theFirebase project's own key: it stages the environment-owned
GCP_SERVICE_ACCOUNTsecret in a mode-0600 runner file and passes
--signer-credentials-file. That laneis green today (run 32999384549), and
.github/AGENTS.md:23prescribes exactly thisshape.
firebase_release_probe_token.py::_read_signer_credentialsalready rejects a signerwhose
project_iddoes not matchfirebase_auth_project_id, so the credentialcannot silently drift.
No IAM change is required — local signing needs no
serviceAccountTokenCreatorgrant. Secret Manager access was never the problem:
secret_accesssucceeded in thefailing runs; the failure was at the later
custom_token_signingstage.The named-signer input is left in place and is only consulted when no credential is
supplied, so nothing that sets it changes behaviour.
sync_ledger_fence_cutover.ymlcarries the same split in its development lane and iswired the same way. Its production lane deploys into
based-hardwareand keepssigning with its active identity, so production is byte-identical there.
Proof
backend/tests/unit/test_firebase_release_probe_token.py— the failure class'sexisting
canonical_prevention_artifact— gains two tests: the development deploylane must supply a Firebase-project signer, and the probe action must stage that key
as transient, owner-only material that does not outlive the probe.
PASSand trafficactually shifting.
🤖 Generated with Claude Code