feat(flags): gate Bridge top-up/KYC queries behind bridgeTopupEnabled (ENG-465)#656
Closed
islandbitcoin wants to merge 1 commit into
Closed
feat(flags): gate Bridge top-up/KYC queries behind bridgeTopupEnabled (ENG-465)#656islandbitcoin wants to merge 1 commit into
islandbitcoin wants to merge 1 commit into
Conversation
… (ENG-465) The Bridge KYC + external-accounts queries fire on mount/focus for every level>=1 user. If the app ships before the backend exposes these fields, all eligible users get GraphQL errors. Add a bridgeTopupEnabled Remote Config flag (default OFF) and Apollo `skip:` the queries + refetch when it's off, so the new bridge fields are never queried until the flag is turned on. ENG-465. Mirrors the existing deviceAccountEnabled skip pattern. Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
Contributor
Author
|
Superseded by #658, which folds the same bridge kill-switch into the #621 epic (feat/fygaro). #656/#657 targeted sibling branches (fix/bridge-kyc-selfie, feat/usdt-display-as-usd) that are not part of the epics being merged. USDT query gating dropped: the USDT cutover is the intended default (flash#413). |
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
Adds a
bridgeTopupEnabledFirebase Remote Config flag (default OFF) and gates the Bridge GraphQL queries behind it with Apolloskip:.feature-flags-context.tsx: newbridgeTopupEnabledflag (default off; on forLocalinstance, mirroringdeviceAccountEnabled)TopupCashout.tsx:skip: !bridgeTopupEnabledonuseBridgeKycStatusQuery+useBridgeExternalAccountsQuery; guard the on-focus refetchAccountType.tsx: same foruseBridgeKycStatusQueryWhy (ENG-465, audit P0)
These queries fire on mount/focus for every level≥1 user. If the app reaches users before the backend exposes
bridgeKycStatus/bridgeExternalAccounts, they hit app-wide GraphQL validation errors. The flag lets us keep the UI dark until the backend is ready, and keeps the FE flag in sync with the backendbridge.enabled.Toggle behavior
Verification
Local full typecheck not run (isolated worktree has no node_modules) — relying on CI. Change is minimal and follows the existing
skip: !deviceAccountEnabledpattern;skipis a standard Apollo query option.🤖 Generated with Claude Code