Skip to content

docs: update feature flag registry documentation#40554

Merged
Unik0rnMaggie merged 6 commits intomainfrom
docs/feature-flag-registry
Mar 5, 2026
Merged

docs: update feature flag registry documentation#40554
Unik0rnMaggie merged 6 commits intomainfrom
docs/feature-flag-registry

Conversation

@Unik0rnMaggie
Copy link
Copy Markdown
Contributor

@Unik0rnMaggie Unik0rnMaggie commented Mar 3, 2026

Description

Add a new Feature Flag Registry section to README.md to document how remote flags are managed for E2E tests.
Explain the full workflow: production source-of-truth, E2E mock behavior, CI enforcement via check-feature-flag-registry, and registry entry format.
Document contributor guidance for adding, overriding, and removing feature flags, including helper utilities and constant mapping requirements.

The feature flag registry and CI check were added to keep flag usage production-accurate and prevent untracked flag references. This documentation makes the workflow discoverable and reduces onboarding/friction for contributors updating or introducing flags.

Open in GitHub Codespaces

Changelog

CHANGELOG entry: null

Related issues

Fixes: MMQA-1481

Manual testing steps

  1. Go to this page...

Screenshots/Recordings

Before

After

Pre-merge author checklist

Pre-merge reviewer checklist

  • I've manually tested the PR (e.g. pull and build branch, run the app, test code being changed).
  • I confirm that this PR addresses all acceptance criteria described in the ticket it closes and includes the necessary testing evidence such as recordings and or screenshots.

Note

Low Risk
Low risk: documentation-only changes with no runtime behavior modifications.

Overview
Updates README.md E2E guidance to clearly separate remote (runtime) vs build-time (compile-time) feature flags and points to the recommended test-time override mechanisms (manifestFlags in withFixtures, legacy FixtureBuilder.withRemoteFeatureFlags()).

Adds a new Feature Flag Registry section documenting test/e2e/feature-flags/feature-flag-registry.ts as the source of truth for remote flags in E2E, how the check-feature-flag-registry CI job enforces registry coverage, and contributor steps to add/override/remove flags (including constant mapping in .github/scripts/known-feature-flag-constants.ts).

Written by Cursor Bugbot for commit 1163560. This will update automatically on new commits. Configure here.

@github-actions
Copy link
Copy Markdown
Contributor

github-actions bot commented Mar 3, 2026

CLA Signature Action: All authors have signed the CLA. You may need to manually re-run the blocking PR check if it doesn't pass in a few minutes.

@metamaskbot metamaskbot added the team-qa QA team label Mar 3, 2026
@github-actions github-actions bot added the size-S label Mar 3, 2026
@metamaskbotv2
Copy link
Copy Markdown
Contributor

metamaskbotv2 bot commented Mar 3, 2026

Builds ready [d601b51]
⚡ Performance Benchmarks
👆 Interaction Benchmarks
BenchmarkMetricMean (ms)Min (ms)Max (ms)Std Dev (ms)P75 (ms)P95 (ms)
Load New Accountload_new_account28226529512292295
total28226529512292295
Confirm Txconfirm_tx6095604861553761136155
total6095604861553761136155
Bridge User Actionsbridge_load_page25120230343300303
bridge_load_asset_picker2142102194219219
bridge_search_token71970173513728735
total1178110412505812381250
🔌 Startup Benchmarks
BenchmarkMetricMean (ms)Min (ms)Max (ms)Std Dev (ms)P75 (ms)P95 (ms)
Standard HomeuiStartup14261208171210514791612
load1192101413879012351365
domContentLoaded1186100913828812281357
domInteractive281797182677
firstPaint160731196127204297
backgroundConnect21219535119215249
firstReactRender20125672129
initialActions107124
loadScripts98981811858610281155
setupStore1364061529
numNetworkReqs312287192381
Power User HomeuiStartup17381376227416217762006
load11471017173615711291602
domContentLoaded11331004169715211131585
domInteractive39192433336111
firstPaint1907849891248375
backgroundConnect28926041527297333
firstReactRender23155972540
initialActions103113
loadScripts92679814971509061376
setupStore1574161725
numNetworkReqs59381472755141
🧭 User Journey Benchmarks
BenchmarkMetricMean (ms)Min (ms)Max (ms)Std Dev (ms)P75 (ms)P95 (ms)
Onboarding Import WalletimportWalletToSocialScreen22621824611230246
srpButtonToSrpForm91899329393
confirmSrpToPwForm21212202222
pwFormToMetricsScreen15141501515
metricsToWalletReadyScreen15151601516
doneButtonToHomeScreen5745665825576582
openAccountMenuToAccountListLoaded73187002784735176277847
total83557940878833785738788
Onboarding New WalletcreateWalletToSocialScreen2212192221221222
srpButtonToPwForm1111101121112112
createPwToRecoveryScreen999099
skipBackupToMetricsScreen37363913739
agreeButtonToOnboardingSuccess17151811818
doneButtonToAssetList835494129335012281293
total1231888168835016251688
Asset DetailsassetClickToPriceChart483465105265
total483465105265
Solana Asset DetailsassetClickToPriceChart48484904949
total48484904949
Import Srp HomeloginToHomeScreen20991911224414122292244
openAccountMenuAfterLogin39344334043
homeAfterImportWithNewWallet2391235624544424542454
total44394314455910045594559
Send TransactionsopenSendPageFromHome37353813738
selectTokenToSendFormLoaded19172122021
reviewTransactionToConfirmationPage8528448596859859
total90388391511913915
SwapopenSwapPageFromHome1018912013113120
fetchAndDisplaySwapQuotes4670457347427147324742
total4768466248627948234862
🌐 Dapp Page Load Benchmarks

Current Commit: d601b51 | Date: 3/3/2026

📄 Localhost MetaMask Test Dapp

Samples: 100

Summary

  • pageLoadTime-> current mean value: 1.06s (±38ms) 🟡 | historical mean value: 1.05s ⬆️ (historical data)
  • domContentLoaded-> current mean value: 725ms (±36ms) 🟢 | historical mean value: 737ms ⬇️ (historical data)
  • firstContentfulPaint-> current mean value: 82ms (±13ms) 🟢 | historical mean value: 82ms ⬇️ (historical data)

📈 Detailed Results

Metric Mean Std Dev Min Max P95 P99
pageLoadTime 1.06s 38ms 1.03s 1.34s 1.08s 1.34s
domContentLoaded 725ms 36ms 704ms 995ms 747ms 995ms
firstPaint 82ms 13ms 64ms 188ms 96ms 188ms
firstContentfulPaint 82ms 13ms 64ms 188ms 96ms 188ms
largestContentfulPaint 0ms 0ms 0ms 0ms 0ms 0ms
Bundle size diffs
  • background: 58 Bytes (0%)
  • ui: 5 Bytes (0%)
  • common: 20 Bytes (0%)

@metamaskbotv2
Copy link
Copy Markdown
Contributor

metamaskbotv2 bot commented Mar 3, 2026

Builds ready [100db3a]
⚡ Performance Benchmarks
👆 Interaction Benchmarks
BenchmarkMetricMean (ms)Min (ms)Max (ms)Std Dev (ms)P75 (ms)P95 (ms)
Load New Accountload_new_account28126132525292325
total28126132525292325
Confirm Txconfirm_tx6038602260471060466047
total6038602260471060466047
Bridge User Actionsbridge_load_page21119522210219222
bridge_load_asset_picker2182062289224228
bridge_search_token71469672811720728
total1150109711943411741194
🔌 Startup Benchmarks
BenchmarkMetricMean (ms)Min (ms)Max (ms)Std Dev (ms)P75 (ms)P95 (ms)
Standard HomeuiStartup14251180165610414811628
load119999514529412471379
domContentLoaded119199314019112421363
domInteractive2817112192474
firstPaint184711322173222347
backgroundConnect21019142324210232
firstReactRender19135152128
initialActions106114
loadScripts99880212079110511169
setupStore1354461521
numNetworkReqs312296202284
Power User HomeuiStartup2222147910057130220614292
load12171058184917112201687
domContentLoaded11981050181616012061593
domInteractive40211562738103
firstPaint218761655221260401
backgroundConnect610269751011143282337
firstReactRender24155282543
initialActions107113
loadScripts98084015761569961376
setupStore1665671828
numNetworkReqs70381542780126
🧭 User Journey Benchmarks
BenchmarkMetricMean (ms)Min (ms)Max (ms)Std Dev (ms)P75 (ms)P95 (ms)
Onboarding Import WalletimportWalletToSocialScreen2202192221221222
srpButtonToSrpForm96969609696
confirmSrpToPwForm21212202122
pwFormToMetricsScreen17151811818
metricsToWalletReadyScreen17151911819
doneButtonToHomeScreen1025598144034814371440
openAccountMenuToAccountListLoaded74657005769528876937695
total88618664905612889119056
Onboarding New WalletcreateWalletToSocialScreen2192172222219222
srpButtonToPwForm1081061112108111
createPwToRecoveryScreen889089
skipBackupToMetricsScreen36353813838
agreeButtonToOnboardingSuccess17171701717
doneButtonToAssetList639481875145619875
total1026871126214510041262
Asset DetailsassetClickToPriceChart493675155475
total493675155475
Solana Asset DetailsassetClickToPriceChart48465024950
total48465024950
Import Srp HomeloginToHomeScreen20421899220513121952205
openAccountMenuAfterLogin41384424244
homeAfterImportWithNewWallet25372418271611925742716
total47574395546640449495466
Send TransactionsopenSendPageFromHome39374014040
selectTokenToSendFormLoaded21202212122
reviewTransactionToConfirmationPage87485290019892900
total93391196118945961
SwapopenSwapPageFromHome1201061309129130
fetchAndDisplaySwapQuotes4603457646503046114650
total4721470047622547174762
🌐 Dapp Page Load Benchmarks

Current Commit: 100db3a | Date: 3/3/2026

📄 Localhost MetaMask Test Dapp

Samples: 100

Summary

  • pageLoadTime-> current mean value: 1.04s (±40ms) 🟡 | historical mean value: 1.05s ⬇️ (historical data)
  • domContentLoaded-> current mean value: 731ms (±38ms) 🟢 | historical mean value: 737ms ⬇️ (historical data)
  • firstContentfulPaint-> current mean value: 79ms (±14ms) 🟢 | historical mean value: 82ms ⬇️ (historical data)

📈 Detailed Results

Metric Mean Std Dev Min Max P95 P99
pageLoadTime 1.04s 40ms 1.02s 1.35s 1.07s 1.35s
domContentLoaded 731ms 38ms 710ms 1.02s 755ms 1.02s
firstPaint 79ms 14ms 64ms 208ms 88ms 208ms
firstContentfulPaint 79ms 14ms 64ms 208ms 88ms 208ms
largestContentfulPaint 0ms 0ms 0ms 0ms 0ms 0ms
Bundle size diffs [🚨 Warning! Bundle size has increased!]
  • background: 58 Bytes (0%)
  • ui: 12.41 KiB (0.15%)
  • common: -414 Bytes (0%)

@metamaskbotv2
Copy link
Copy Markdown
Contributor

metamaskbotv2 bot commented Mar 4, 2026

Builds ready [b82354c]
⚡ Performance Benchmarks
👆 Interaction Benchmarks
BenchmarkMetricMean (ms)Min (ms)Max (ms)Std Dev (ms)P75 (ms)P95 (ms)
Load New Accountload_new_account29426135133310351
total29426135133310351
Confirm Txconfirm_tx6034599360542360516054
total6034599360542360516054
Bridge User Actionsbridge_load_page21219323014218230
bridge_load_asset_picker23416630345251303
bridge_search_token71969973716732737
total1199109513549612611354
🔌 Startup Benchmarks
BenchmarkMetricMean (ms)Min (ms)Max (ms)Std Dev (ms)P75 (ms)P95 (ms)
Standard HomeuiStartup1402118917069914221599
load1177100214268912041355
domContentLoaded117099714178812011348
domInteractive281795172578
firstPaint157681202132210337
backgroundConnect20619325412209235
firstReactRender19124452129
initialActions105123
loadScripts97981012268710091147
setupStore1274251419
numNetworkReqs312286192583
Power User HomeuiStartup243914059787152722714662
load12021013189816412451602
domContentLoaded11851008171415712181591
domInteractive39191862639100
firstPaint190791731172247305
backgroundConnect764259799811954272505
firstReactRender24164572739
initialActions106114
loadScripts972821150214810111346
setupStore1564361732
numNetworkReqs74321642784131
🧭 User Journey Benchmarks
BenchmarkMetricMean (ms)Min (ms)Max (ms)Std Dev (ms)P75 (ms)P95 (ms)
Onboarding Import WalletimportWalletToSocialScreen2182182180218218
srpButtonToSrpForm94939519595
confirmSrpToPwForm21212202222
pwFormToMetricsScreen15151501515
metricsToWalletReadyScreen16161701717
doneButtonToHomeScreen63459370139653701
openAccountMenuToAccountListLoaded2927290129491929472949
total3934388140104839674010
Onboarding New WalletcreateWalletToSocialScreen2212192242223224
srpButtonToPwForm1121081174116117
createPwToRecoveryScreen98100910
skipBackupToMetricsScreen37354123941
agreeButtonToOnboardingSuccess17161811818
doneButtonToAssetList60658262015616620
total10019901011910091011
Asset DetailsassetClickToPriceChart664194217894
total664194217894
Solana Asset DetailsassetClickToPriceChart1097119246125192
total1097119246125192
Import Srp HomeloginToHomeScreen1939185820346319382034
openAccountMenuAfterLogin433359115359
homeAfterImportWithNewWallet2634254227719927402771
total45804433473711346224737
Send TransactionsopenSendPageFromHome23192732527
selectTokenToSendFormLoaded22222312323
reviewTransactionToConfirmationPage8498468522850852
total8958948950895895
SwapopenSwapPageFromHome1181151202120120
fetchAndDisplaySwapQuotes289928942904429022904
total301730123022430193022
🌐 Dapp Page Load Benchmarks

Current Commit: b82354c | Date: 3/4/2026

📄 Localhost MetaMask Test Dapp

Samples: 100

Summary

  • pageLoadTime-> current mean value: 966ms (±40ms) 🟢 | historical mean value: 1.06s ⬇️ (historical data)
  • domContentLoaded-> current mean value: 679ms (±36ms) 🟢 | historical mean value: 748ms ⬇️ (historical data)
  • firstContentfulPaint-> current mean value: 76ms (±10ms) 🟢 | historical mean value: 83ms ⬇️ (historical data)

📈 Detailed Results

Metric Mean Std Dev Min Max P95 P99
pageLoadTime 966ms 40ms 941ms 1.24s 988ms 1.24s
domContentLoaded 679ms 36ms 656ms 941ms 695ms 941ms
firstPaint 76ms 10ms 64ms 160ms 88ms 160ms
firstContentfulPaint 76ms 10ms 64ms 160ms 88ms 160ms
largestContentfulPaint 0ms 0ms 0ms 0ms 0ms 0ms
Bundle size diffs [🚨 Warning! Bundle size has increased!]
  • background: 1.13 KiB (0.02%)
  • ui: 6.51 KiB (0.08%)
  • common: 4.34 KiB (0.04%)

LeVinhGithub
LeVinhGithub previously approved these changes Mar 4, 2026
@sonarqubecloud
Copy link
Copy Markdown

sonarqubecloud bot commented Mar 4, 2026

@metamaskbotv2
Copy link
Copy Markdown
Contributor

metamaskbotv2 bot commented Mar 4, 2026

Builds ready [1163560]
⚡ Performance Benchmarks
👆 Interaction Benchmarks
BenchmarkMetricMean (ms)Min (ms)Max (ms)Std Dev (ms)P75 (ms)P95 (ms)
Load New Accountload_new_account34926552096385520
total34926552096385520
Confirm Txconfirm_tx6050600160813460816081
total6050600160813460816081
Bridge User Actionsbridge_load_page2462362517251251
bridge_load_asset_picker21515529649244296
bridge_search_token72669876021736760
total1152110312013511551201
🔌 Startup Benchmarks
BenchmarkMetricMean (ms)Min (ms)Max (ms)Std Dev (ms)P75 (ms)P95 (ms)
Standard HomeuiStartup14261227176810514651653
load119799514679212331372
domContentLoaded119199014619112271365
domInteractive271792162569
firstPaint1497044774201276
backgroundConnect21519428515220244
firstReactRender19124752027
initialActions106124
loadScripts99179112749010301160
setupStore1365371521
numNetworkReqs322298202284
Power User HomeuiStartup17471412266616917881963
load11811060169114411861575
domContentLoaded11671050167914211661569
domInteractive3921197273695
firstPaint1777848490240352
backgroundConnect30626372648312340
firstReactRender23165262437
initialActions104112
loadScripts95083614311369511339
setupStore1593041723
numNetworkReqs60361522560133
🧭 User Journey Benchmarks
BenchmarkMetricMean (ms)Min (ms)Max (ms)Std Dev (ms)P75 (ms)P95 (ms)
Onboarding Import WalletimportWalletToSocialScreen2212192232222223
srpButtonToSrpForm99981021100102
confirmSrpToPwForm24242502525
pwFormToMetricsScreen18181801818
metricsToWalletReadyScreen18181801818
doneButtonToHomeScreen715604880109807880
openAccountMenuToAccountListLoaded2936291129632129492963
total398039733989739893989
Onboarding New WalletcreateWalletToSocialScreen2182172191219219
srpButtonToPwForm1191091298125129
createPwToRecoveryScreen989099
skipBackupToMetricsScreen36363713737
agreeButtonToOnboardingSuccess16161601616
doneButtonToAssetList56049666065611660
total95988310596910201059
Asset DetailsassetClickToPriceChart45385154951
total45385154951
Solana Asset DetailsassetClickToPriceChart83838418484
total83838418484
Import Srp HomeloginToHomeScreen2109200322107821722210
openAccountMenuAfterLogin39305074350
homeAfterImportWithNewWallet30052812323215730693232
total5154503452718852355271
Send TransactionsopenSendPageFromHome23182632526
selectTokenToSendFormLoaded23183352533
reviewTransactionToConfirmationPage8548498667851866
total8998889098903909
SwapopenSwapPageFromHome1137914022131140
fetchAndDisplaySwapQuotes2907289329271229152927
total3020299430391830383039
🌐 Dapp Page Load Benchmarks

Current Commit: 1163560 | Date: 3/4/2026

📄 Localhost MetaMask Test Dapp

Samples: 100

Summary

  • pageLoadTime-> current mean value: 1.05s (±42ms) 🟡 | historical mean value: 1.06s ⬇️ (historical data)
  • domContentLoaded-> current mean value: 736ms (±39ms) 🟢 | historical mean value: 746ms ⬇️ (historical data)
  • firstContentfulPaint-> current mean value: 81ms (±9ms) 🟢 | historical mean value: 82ms ⬇️ (historical data)

📈 Detailed Results

Metric Mean Std Dev Min Max P95 P99
pageLoadTime 1.05s 42ms 1.02s 1.35s 1.09s 1.35s
domContentLoaded 736ms 39ms 708ms 1.03s 764ms 1.03s
firstPaint 81ms 9ms 64ms 156ms 92ms 156ms
firstContentfulPaint 81ms 9ms 64ms 156ms 92ms 156ms
largestContentfulPaint 0ms 0ms 0ms 0ms 0ms 0ms
Bundle size diffs [🚨 Warning! Bundle size has increased!]
  • background: 1.45 KiB (0.03%)
  • ui: 11.15 KiB (0.13%)
  • common: 4.16 KiB (0.04%)

@DDDDDanica
Copy link
Copy Markdown
Contributor

LGTM ! ✅

@Unik0rnMaggie Unik0rnMaggie added this pull request to the merge queue Mar 5, 2026
Merged via the queue into main with commit 306e67a Mar 5, 2026
85 checks passed
@Unik0rnMaggie Unik0rnMaggie deleted the docs/feature-flag-registry branch March 5, 2026 10:02
@github-actions github-actions bot locked and limited conversation to collaborators Mar 5, 2026
@metamaskbot metamaskbot added the release-13.22.0 Issue or pull request that will be included in release 13.22.0 label Mar 5, 2026
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

release-13.22.0 Issue or pull request that will be included in release 13.22.0 size-S team-qa QA team

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants