Skip to content

Conversation

@lionellbriones
Copy link
Contributor

@lionellbriones lionellbriones commented Nov 21, 2025

Description

Shield Plan page: adds UI for handling for api errors

Back button

  • redirects to settings page if shield plan page is opened from Shield entry modal from settings
  • redirects to home page if shield plan is opened from Shield entry modal from home page or post transaction

Try again
Reloads metamask extension

Open in GitHub Codespaces

Changelog

CHANGELOG entry: adds UI for handling for api errors on shield plan page

Related issues

Fixes:

Manual testing steps

  1. Login to an account without shield subscription
  2. Go to Menu > Settings
  3. Click on Transaction Shield (opens shield entry modal)
  4. Click on getting started (redirects to shield plan subscription page)
  5. Open Chrome developer tools > Network tab
  6. Change throttling to offline
  7. Submit the form (API error UI should show)

Screenshots/Recordings

Before

After

Screenshot 2025-11-21 at 3 07 05 PM Screenshot 2025-11-21 at 3 06 40 PM

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

Adds an API error screen with retry on Shield Plan, routes back to Settings or Home based on entry source, updates e2e tests, and introduces a new i18n string.

  • Shield Plan UI:
    • API Error Handling: Compute hasApiError from subscription/pricing/balances/subscriptionResult; show ApiErrorHandler (with retry reload) instead of content; only show LoadingScreen when no error.
    • Navigation: Back button now routes to settings or default based on source query param (EntryModalSourceEnum); uses useLocation.
    • Styling: Adds .shield-plan-page__error-content spacing.
    • Components: New ui/components/app/api-error-handler (icon, message shieldPlanErrorText, "Try again" reload); exported via index.
  • i18n:
    • Add shieldPlanErrorText to app/_locales/en/messages.json and app/_locales/en_GB/messages.json.
  • Tests (E2E):
    • Add back-navigation tests (to Home/Settings) and subscription flows from Settings.
    • Use mockNotEligible: true for settings-origin flows; minor flow adjustments.

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

@lionellbriones lionellbriones requested a review from a team as a code owner November 21, 2025 08:13
@github-actions
Copy link
Contributor

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
Copy link
Collaborator

metamaskbot commented Nov 21, 2025

✨ Files requiring CODEOWNER review ✨

🔐 @MetaMask/web3auth (2 files, +238 -200)
  • 📁 ui/
    • 📁 pages/
      • 📁 shield-plan/
        • 📄 index.scss +5 -0
        • 📄 shield-plan.tsx +233 -200

@metamaskbot
Copy link
Collaborator

Builds ready [15b795a]
UI Startup Metrics (1225 ± 106 ms)
PlatformBuildTypePageMetricMean (ms)Min (ms)Max (ms)Std Dev (ms)P 75 (ms)P 95 (ms)
ChromeBrowserifyStandard HomeuiStartup12251065156710612721430
load103687212669310901211
domContentLoaded102984112609310831205
domInteractive241496191975
firstPaint603102127643810531215
backgroundConnect21219628612216230
firstReactRender29175083245
getState341674124157
initialActions105112
loadScripts824644105692880999
setupStore1272741422
numNetworkReqs1257720573
BrowserifyPower User HomeuiStartup18661552374432120262575
load96884919351939491501
domContentLoaded95484019251929331492
domInteractive33151743527136
firstPaint63216516393849051357
backgroundConnect20819228813212235
firstReactRender80501271490107
getState18913939351208323
initialActions103112
loadScripts76165016471867411284
setupStore1794982333
numNetworkReqs1196828649141211
WebpackStandard HomeuiStartup826730106676854995
load62457184563631784
domContentLoaded61956783562625778
domInteractive2414102192176
firstPaint21192843129215595
backgroundConnect1253271530
firstReactRender3221247233439
getState291351103747
initialActions103112
loadScripts61656482760623769
setupStore1273141420
numNetworkReqs1257720572
WebpackPower User HomeuiStartup14491059211424115921991
load67957611461336911075
domContentLoaded66756811391316731052
domInteractive37171873631144
firstPaint2951011114218305718
backgroundConnect1574381933
firstReactRender8052107118698
getState15612225425168207
initialActions103012
loadScripts66556611291296711042
setupStore22857123242
numNetworkReqs1456830356185282
FirefoxBrowserifyStandard HomeuiStartup12511104153110413181458
load105594613227811071210
domContentLoaded105394013177911071210
domInteractive65292504391155
firstPaint------
backgroundConnect3522172173948
firstReactRender21184642227
getState106718916
initialActions103012
loadScripts103492912967710871191
setupStore12675111035
numNetworkReqs1156614652
BrowserifyPower User HomeuiStartup26471911380432928173376
load1141935166116011791455
domContentLoaded1140929166116111791454
domInteractive13932624120159442
firstPaint------
backgroundConnect227241029252327833
firstReactRender86521511794124
getState24676896248207857
initialActions207227
loadScripts1090916163814711061427
setupStore1197762167125574
numNetworkReqs98512214393208
WebpackStandard HomeuiStartup14031268185811314441661
load1200107114559112701381
domContentLoaded1200107114559112691380
domInteractive59282304083136
firstPaint------
backgroundConnect3918123194290
firstReactRender26196562735
getState116112121122
initialActions102012
loadScripts1176104813908512431326
setupStore1168291031
numNetworkReqs1257117662
WebpackPower User HomeuiStartup28922183372434231143544
load14121131202920015921769
domContentLoaded14121131202820015921768
domInteractive13028537120137455
firstPaint------
backgroundConnect17428822178203623
firstReactRender88411912495135
getState28883903277398875
initialActions4153827
loadScripts13751108192319215451740
setupStore1087776164110525
numNetworkReqs98612374392207
📊 Page Load Benchmark Results

Current Commit: 15b795a | Date: 11/21/2025

📄 Localhost MetaMask Test Dapp

Samples: 100

Summary

  • pageLoadTime-> current mean value: 990ms (±41ms) 🟢 | historical mean value: 1.05s ⬇️ (historical data)
  • domContentLoaded-> current mean value: 685ms (±36ms) 🟢 | historical mean value: 732ms ⬇️ (historical data)
  • firstContentfulPaint-> current mean value: 75ms (±12ms) 🟢 | historical mean value: 78ms ⬇️ (historical data)

📈 Detailed Results

Metric Mean Std Dev Min Max P95 P99
pageLoadTime 990ms 41ms 964ms 1.29s 1.02s 1.29s
domContentLoaded 685ms 36ms 663ms 953ms 717ms 953ms
firstPaint 75ms 12ms 60ms 184ms 84ms 184ms
firstContentfulPaint 75ms 12ms 60ms 184ms 84ms 184ms
largestContentfulPaint 0ms 0ms 0ms 0ms 0ms 0ms
Bundle size diffs [🚨 Warning! Bundle size has increased!]
  • background: 53 Bytes (0%)
  • ui: 965 Bytes (0.01%)
  • common: 93 Bytes (0%)

@metamaskbot
Copy link
Collaborator

Builds ready [4df4ceb]
UI Startup Metrics (1231 ± 94 ms)
PlatformBuildTypePageMetricMean (ms)Min (ms)Max (ms)Std Dev (ms)P 75 (ms)P 95 (ms)
ChromeBrowserifyStandard HomeuiStartup1231102914739412871423
load104588712858811131207
domContentLoaded103788412718811071202
domInteractive2414123202081
firstPaint540100129241510421183
backgroundConnect21718930114221246
firstReactRender311968103947
getState341775124060
initialActions107112
loadScripts828682106290904997
setupStore1262951322
numNetworkReqs1257720573
BrowserifyPower User HomeuiStartup19711627261924421592446
load1045917165217010431549
domContentLoaded1028904162316910251537
domInteractive38172164131162
firstPaint5729516624109731142
backgroundConnect22620727411233251
firstReactRender81501251489112
getState19113339250217300
initialActions104112
loadScripts81970414211688201322
setupStore2085092539
numNetworkReqs1316428854171245
WebpackStandard HomeuiStartup8167381031708411011
load61455881763621791
domContentLoaded60955381263618784
domInteractive2414100182076
firstPaint23781788157227618
backgroundConnect1253881629
firstReactRender29208883339
getState301354103748
initialActions105112
loadScripts60655180161616775
setupStore1263251421
numNetworkReqs1257720571
WebpackPower User HomeuiStartup14991246226123716511942
load69360111231257101047
domContentLoaded68259311161236921036
domInteractive39171773932155
firstPaint292951125206315701
backgroundConnect1684871928
firstReactRender85541851693105
getState16012830133163235
initialActions103012
loadScripts67959111071216891027
setupStore22965142860
numNetworkReqs1426632456182275
FirefoxBrowserifyStandard HomeuiStartup12251057174311812721444
load103291012538210921204
domContentLoaded103190512538310921204
domInteractive61302354182159
firstPaint------
backgroundConnect38202022838101
firstReactRender22174852235
getState11513317920
initialActions103112
loadScripts101289312318010691179
setupStore1156391027
numNetworkReqs1157016762
BrowserifyPower User HomeuiStartup27111910396839529513510
load1195975175019713441609
domContentLoaded1195974175019713441609
domInteractive13632677130153473
firstPaint------
backgroundConnect21227915229247748
firstReactRender89521522196133
getState22284889216191828
initialActions218227
loadScripts1155957173018912501518
setupStore1216797186115752
numNetworkReqs88502174381194
WebpackStandard HomeuiStartup14161210198212814491715
load1208105214859712641424
domContentLoaded1208105214859712641424
domInteractive60261683579130
firstPaint------
backgroundConnect3716122194193
firstReactRender27206982840
getState1064671022
initialActions102012
loadScripts1185103614418812421358
setupStore11682111031
numNetworkReqs1156916663
WebpackPower User HomeuiStartup28332133381634030523469
load13891110190319515791752
domContentLoaded13891109190219515791752
domInteractive12833574122153466
firstPaint------
backgroundConnect13526672144163572
firstReactRender894617823100128
getState25686954263198867
initialActions4141637
loadScripts13571091182818615361697
setupStore1386796216111754
numNetworkReqs90592064287202
📊 Page Load Benchmark Results

Current Commit: 4df4ceb | Date: 11/21/2025

📄 Localhost MetaMask Test Dapp

Samples: 100

Summary

  • pageLoadTime-> current mean value: 1.04s (±37ms) 🟡 | historical mean value: 1.04s ⬇️ (historical data)
  • domContentLoaded-> current mean value: 722ms (±35ms) 🟢 | historical mean value: 727ms ⬇️ (historical data)
  • firstContentfulPaint-> current mean value: 78ms (±11ms) 🟢 | historical mean value: 79ms ⬇️ (historical data)

📈 Detailed Results

Metric Mean Std Dev Min Max P95 P99
pageLoadTime 1.04s 37ms 1.01s 1.29s 1.06s 1.29s
domContentLoaded 722ms 35ms 696ms 972ms 745ms 972ms
firstPaint 78ms 11ms 60ms 168ms 88ms 168ms
firstContentfulPaint 78ms 11ms 60ms 168ms 88ms 168ms
largestContentfulPaint 0ms 0ms 0ms 0ms 0ms 0ms
Bundle size diffs [🚨 Warning! Bundle size has increased!]
  • background: 53 Bytes (0%)
  • ui: 965 Bytes (0.01%)
  • common: 93 Bytes (0%)

tuna1207
tuna1207 previously approved these changes Nov 24, 2025
chaitanyapotti
chaitanyapotti previously approved these changes Nov 24, 2025
@chaitanyapotti chaitanyapotti added this pull request to the merge queue Nov 24, 2025
@github-merge-queue github-merge-queue bot removed this pull request from the merge queue due to failed status checks Nov 24, 2025
subscriptionsError ||
subscriptionPricingError ||
availableTokenBalancesError ||
subscriptionResult.error;
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Bug: Error UI shows for non-critical API failures

The hasApiError check combines errors from all subscription hooks, but it shows an error UI even when non-critical data fails to load (like availableTokenBalancesError). This means users see an error page and "Try Again" button even if subscriptionPricing loaded successfully and the page could display plan details. The error UI should only show when critical data like subscriptionPricing or the actual subscription request fails.

Additional Locations (1)

Fix in Cursor Fix in Web

@metamaskbot
Copy link
Collaborator

Builds ready [8eccbfc]
UI Startup Metrics (1209 ± 91 ms)
PlatformBuildTypePageMetricMean (ms)Min (ms)Max (ms)Std Dev (ms)P 75 (ms)P 95 (ms)
ChromeBrowserifyStandard HomeuiStartup120999816219112471372
load102485313187810511176
domContentLoaded101785013117710451165
domInteractive2515116222087
firstPaint55789122639810141142
backgroundConnect21019025210212236
firstReactRender2920206193143
getState331667113958
initialActions104112
loadScripts814660109576837965
setupStore1154551118
numNetworkReqs1257821573
BrowserifyPower User HomeuiStartup19271601325027820282476
load97787017221409711343
domContentLoaded96386517141409531336
domInteractive35171743230128
firstPaint6839114443799591305
backgroundConnect21919325712225241
firstReactRender924417422104134
getState17914325826194237
initialActions103112
loadScripts76066715071387491133
setupStore19969112045
numNetworkReqs101652925795285
WebpackStandard HomeuiStartup821694107479855991
load63955282775682790
domContentLoaded63554782174678785
domInteractive2615100212294
firstPaint21374826152199612
backgroundConnect952741218
firstReactRender26205563035
getState261358103345
initialActions102111
loadScripts63254581173676781
setupStore1062641219
numNetworkReqs1257820575
WebpackPower User HomeuiStartup16411225218620917811957
load6635831164101670940
domContentLoaded6535781157101656934
domInteractive35171863132124
firstPaint291105964209292707
backgroundConnect1675491738
firstReactRender84451071492103
getState14610717913154170
initialActions103112
loadScripts650575114899654926
setupStore21854132450
numNetworkReqs1606540073198385
FirefoxBrowserifyStandard HomeuiStartup12441069191012813031515
load103988615399110911186
domContentLoaded103788115389110911186
domInteractive58301363182131
firstPaint------
backgroundConnect4020317373894
firstReactRender22174552235
getState126130151033
initialActions102012
loadScripts101687213798010671163
setupStore126106121225
numNetworkReqs1156816760
BrowserifyPower User HomeuiStartup25151755353831926973094
load1117970166813711191468
domContentLoaded1116968166713711191468
domInteractive1183351597111347
firstPaint------
backgroundConnect1063650270118195
firstReactRender87541662397133
getState27557847217404771
initialActions2011227
loadScripts1075941160412210871376
setupStore15710827204136631
numNetworkReqs100603176777309
WebpackStandard HomeuiStartup14431285200113914871771
load12181075160810612871428
domContentLoaded12181075160810612871427
domInteractive55252023772130
firstPaint------
backgroundConnect45202132946106
firstReactRender27197693035
getState106576918
initialActions102012
loadScripts1194106115939912651376
setupStore166206301136
numNetworkReqs1256517663
WebpackPower User HomeuiStartup26302076342028028233115
load13311102180317914321699
domContentLoaded13311102179717914311699
domInteractive1062743389101350
firstPaint------
backgroundConnect1002847473120272
firstReactRender80381401890113
getState26766851223423789
initialActions3141427
loadScripts12881080176417113691679
setupStore111563816682577
numNetworkReqs97542435682236
📊 Page Load Benchmark Results

Current Commit: 8eccbfc | Date: 11/25/2025

📄 Localhost MetaMask Test Dapp

Samples: 100

Summary

  • pageLoadTime-> current mean value: 1.04s (±40ms) 🟡 | historical mean value: 1.03s ⬆️ (historical data)
  • domContentLoaded-> current mean value: 726ms (±36ms) 🟢 | historical mean value: 718ms ⬆️ (historical data)
  • firstContentfulPaint-> current mean value: 78ms (±13ms) 🟢 | historical mean value: 77ms ⬆️ (historical data)

📈 Detailed Results

Metric Mean Std Dev Min Max P95 P99
pageLoadTime 1.04s 40ms 1.02s 1.32s 1.09s 1.32s
domContentLoaded 726ms 36ms 702ms 989ms 749ms 989ms
firstPaint 78ms 13ms 60ms 188ms 88ms 188ms
firstContentfulPaint 78ms 13ms 60ms 188ms 88ms 188ms
largestContentfulPaint 0ms 0ms 0ms 0ms 0ms 0ms
Bundle size diffs [🚨 Warning! Bundle size has increased!]
  • background: 53 Bytes (0%)
  • ui: 965 Bytes (0.01%)
  • common: 93 Bytes (0%)

@metamaskbot
Copy link
Collaborator

Builds ready [1343384]
UI Startup Metrics (1252 ± 94 ms)
PlatformBuildTypePageMetricMean (ms)Min (ms)Max (ms)Std Dev (ms)P 75 (ms)P 95 (ms)
ChromeBrowserifyStandard HomeuiStartup1252107915419412881459
load105488112988210861207
domContentLoaded104887512898110811201
domInteractive29141532822110
firstPaint49214613043909961206
backgroundConnect2131952499217229
firstReactRender28195493248
getState331895123657
initialActions106113
loadScripts841664108079874989
setupStore1175461224
numNetworkReqs1257720573
BrowserifyPower User HomeuiStartup20371592263626622242554
load97688014361289631383
domContentLoaded96387414281289451369
domInteractive34172633432116
firstPaint5758314353979431373
backgroundConnect21819724410224240
firstReactRender86441482197130
getState16813025726184221
initialActions1012112
loadScripts76066712201287451171
setupStore20963112345
numNetworkReqs1406739272181344
WebpackStandard HomeuiStartup8277001209878561029
load64556398185687829
domContentLoaded64055897084682822
domInteractive2615121232090
firstPaint23376976190200719
backgroundConnect1054761225
firstReactRender27206473137
getState24136093141
initialActions104111
loadScripts63755596882680814
setupStore1062641218
numNetworkReqs1257720575
WebpackPower User HomeuiStartup16391239221623418032070
load670586102999673971
domContentLoaded6605801023100656964
domInteractive36181803332127
firstPaint26992973188250672
backgroundConnect1574371732
firstReactRender84451231492103
getState14912519816157183
initialActions103012
loadScripts657578101498654954
setupStore211063132350
numNetworkReqs1537539973191325
FirefoxBrowserifyStandard HomeuiStartup12111052171512612791503
load101289812278210821153
domContentLoaded101189812278210781153
domInteractive56291853581124
firstPaint------
backgroundConnect3621132213889
firstReactRender22175362135
getState95839818
initialActions103112
loadScripts98988111627610571132
setupStore12520222826
numNetworkReqs1156716660
BrowserifyPower User HomeuiStartup24461819312425626372883
load1136954160814911391490
domContentLoaded1135954160814911391490
domInteractive1213444695113392
firstPaint------
backgroundConnect993045264118185
firstReactRender84461562194125
getState19961836163214561
initialActions3130427
loadScripts1098938157614311011434
setupStore14913659175191607
numNetworkReqs100613156778307
WebpackStandard HomeuiStartup14191277189511914821682
load1197106314449212821378
domContentLoaded1196106214439212821378
domInteractive53272123671148
firstPaint------
backgroundConnect4121120194476
firstReactRender26196972834
getState126168181024
initialActions102012
loadScripts1174104413788612581338
setupStore14591151348
numNetworkReqs1156815653
WebpackPower User HomeuiStartup27212115369532330223270
load13621119186219413651809
domContentLoaded13621119186219413651809
domInteractive1082948010597412
firstPaint------
backgroundConnect973045164115193
firstReactRender84411421795111
getState30363930238504783
initialActions4169837
loadScripts13241099184218813251780
setupStore1396787189116686
numNetworkReqs100632466076239
📊 Page Load Benchmark Results

Current Commit: 1343384 | Date: 11/25/2025

📄 Localhost MetaMask Test Dapp

Samples: 100

Summary

  • pageLoadTime-> current mean value: 1.04s (±40ms) 🟡 | historical mean value: 1.03s ⬆️ (historical data)
  • domContentLoaded-> current mean value: 730ms (±38ms) 🟢 | historical mean value: 718ms ⬆️ (historical data)
  • firstContentfulPaint-> current mean value: 76ms (±10ms) 🟢 | historical mean value: 77ms ⬇️ (historical data)

📈 Detailed Results

Metric Mean Std Dev Min Max P95 P99
pageLoadTime 1.04s 40ms 1.02s 1.33s 1.08s 1.33s
domContentLoaded 730ms 38ms 708ms 996ms 756ms 996ms
firstPaint 76ms 10ms 60ms 160ms 88ms 160ms
firstContentfulPaint 76ms 10ms 60ms 160ms 88ms 160ms
largestContentfulPaint 0ms 0ms 0ms 0ms 0ms 0ms
Bundle size diffs [🚨 Warning! Bundle size has increased!]
  • background: 53 Bytes (0%)
  • ui: 965 Bytes (0.01%)
  • common: 93 Bytes (0%)

</Button>
</Box>
</Content>
) : (
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Bug: Error UI shown while data is loading

The error UI is displayed whenever hasApiError is true, even when data is still loading. According to the PR discussion, showing error UI while loading is unintended—the main content should display in the background with a loading indicator on top. The condition should exclude errors that occur during the loading state by checking !loading before displaying the error UI.

Additional Locations (1)

Fix in Cursor Fix in Web

paddingTop={2}
className="shield-plan-page__plans"
{loading && !hasApiError && <LoadingScreen />}
{hasApiError ? (
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Bug: Error UI shown during simultaneous loading operations

When multiple independent async operations run in parallel (subscriptions, pricing, token balances), one could fail while another is still loading. Currently, hasApiError condition displays error UI regardless of loading state. However, the PR comment indicates "not showing the error ui while loading is intended". When loading is true, the error UI should not be displayed. The condition should check hasApiError && !loading instead of just hasApiError to match the stated intent.

Fix in Cursor Fix in Web

@metamaskbot
Copy link
Collaborator

Builds ready [6d5cb67]
UI Startup Metrics (1222 ± 100 ms)
PlatformBuildTypePageMetricMean (ms)Min (ms)Max (ms)Std Dev (ms)P 75 (ms)P 95 (ms)
ChromeBrowserifyStandard HomeuiStartup12221014152810012611434
load103186812808210711202
domContentLoaded102586612718110651192
domInteractive2614118232098
firstPaint5438612844029871179
backgroundConnect2101942529215229
firstReactRender28184873142
getState331595143468
initialActions102112
loadScripts821664107180860984
setupStore1072731118
numNetworkReqs1257720574
BrowserifyPower User HomeuiStartup20721599333229622562638
load99287717541479751370
domContentLoaded97886817441469581362
domInteractive34171893429138
firstPaint5808217564079371372
backgroundConnect21920225910223242
firstReactRender88461502199129
getState16612623624180216
initialActions108112
loadScripts77667315381457581154
setupStore2310153182545
numNetworkReqs1526938970187324
WebpackStandard HomeuiStartup8807291337979141095
load684583104297748869
domContentLoaded679577103596742862
domInteractive30161642723102
firstPaint23286867155214624
backgroundConnect1053651027
firstReactRender29205073439
getState261467103446
initialActions105112
loadScripts676575102294740853
setupStore1152941421
numNetworkReqs1257820572
WebpackPower User HomeuiStartup16461243257222318181983
load6605861258106652908
domContentLoaded6505791249107638902
domInteractive36161753430130
firstPaint25578947166269635
backgroundConnect1574361730
firstReactRender84451531795104
getState14612420815155180
initialActions104112
loadScripts6475771241105636892
setupStore191059132150
numNetworkReqs1556840277197383
FirefoxBrowserifyStandard HomeuiStartup12381056174611812881480
load103490112867610901160
domContentLoaded103390112867710891160
domInteractive62301653484134
firstPaint------
backgroundConnect3522143163664
firstReactRender24177182345
getState146144221051
initialActions102122
loadScripts101388612617310661139
setupStore1064271027
numNetworkReqs1157216760
BrowserifyPower User HomeuiStartup24892022323825126343081
load1134938161713411551460
domContentLoaded1133938160913411541459
domInteractive1123345592112382
firstPaint------
backgroundConnect1084048773130251
firstReactRender86561441896124
getState289571256244437836
initialActions2034326
loadScripts1096908150012311221398
setupStore1399800185115636
numNetworkReqs986525748119245
WebpackStandard HomeuiStartup14551314196511214971713
load1232110114768612861426
domContentLoaded1232110114768612851425
domInteractive70291793695132
firstPaint------
backgroundConnect4220123224396
firstReactRender26214042836
getState146164201340
initialActions102012
loadScripts1207108314267812651359
setupStore1263981136
numNetworkReqs1256517664
WebpackPower User HomeuiStartup28632145363427230243428
load15001171192416715921906
domContentLoaded14991171192416615921905
domInteractive12437544106121412
firstPaint------
backgroundConnect1162954061143218
firstReactRender915018720103130
getState30760885240507793
initialActions3146537
loadScripts14601152187715915121842
setupStore851064010680289
numNetworkReqs100622565779240
📊 Page Load Benchmark Results

Current Commit: 6d5cb67 | Date: 11/25/2025

📄 Localhost MetaMask Test Dapp

Samples: 100

Summary

  • pageLoadTime-> current mean value: 1.07s (±45ms) 🟡 | historical mean value: 1.04s ⬆️ (historical data)
  • domContentLoaded-> current mean value: 744ms (±41ms) 🟢 | historical mean value: 721ms ⬆️ (historical data)
  • firstContentfulPaint-> current mean value: 80ms (±10ms) 🟢 | historical mean value: 81ms ⬇️ (historical data)

📈 Detailed Results

Metric Mean Std Dev Min Max P95 P99
pageLoadTime 1.07s 45ms 1.04s 1.38s 1.08s 1.38s
domContentLoaded 744ms 41ms 721ms 1.03s 761ms 1.03s
firstPaint 80ms 10ms 64ms 168ms 88ms 168ms
firstContentfulPaint 80ms 10ms 64ms 168ms 88ms 168ms
largestContentfulPaint 0ms 0ms 0ms 0ms 0ms 0ms
Bundle size diffs [🚨 Warning! Bundle size has increased!]
  • background: 53 Bytes (0%)
  • ui: 965 Bytes (0.01%)
  • common: 93 Bytes (0%)

@github-actions github-actions bot added size-L and removed size-M labels Nov 25, 2025
@metamaskbot
Copy link
Collaborator

Builds ready [5071d81]
UI Startup Metrics (1230 ± 108 ms)
PlatformBuildTypePageMetricMean (ms)Min (ms)Max (ms)Std Dev (ms)P 75 (ms)P 95 (ms)
ChromeBrowserifyStandard HomeuiStartup12301025157210812861433
load104386413499310721216
domContentLoaded103785913429210671207
domInteractive2715133242194
firstPaint50182122039710211202
backgroundConnect2121982408216225
firstReactRender29195283444
getState321668113657
initialActions103112
loadScripts8316601122908611007
setupStore1063031114
numNetworkReqs1257821574
BrowserifyPower User HomeuiStartup20411623310928422192544
load99189117261419811361
domContentLoaded97688417091419661352
domInteractive34181793331140
firstPaint4869513633389121002
backgroundConnect22220226813228247
firstReactRender85441411791114
getState16712826525182205
initialActions108112
loadScripts77368114781397581155
setupStore221075132547
numNetworkReqs1396938971182295
WebpackStandard HomeuiStartup813682112885855987
load62654489472672782
domContentLoaded62153988672668775
domInteractive2615120232096
firstPaint245108892171215683
backgroundConnect953041017
firstReactRender2920162163347
getState251352103243
initialActions104112
loadScripts61853687971666767
setupStore1064551316
numNetworkReqs1257720573
WebpackPower User HomeuiStartup16481207259424218002010
load6555711338115647929
domContentLoaded6455651331115635923
domInteractive35171453131127
firstPaint31989988212570664
backgroundConnect1465771628
firstReactRender87431201697109
getState16013519913169185
initialActions104112
loadScripts6425631322113633913
setupStore20861132250
numNetworkReqs1627142079190390
FirefoxBrowserifyStandard HomeuiStartup12581097170711513191483
load105191212797911241196
domContentLoaded105091212787911241196
domInteractive60302073283120
firstPaint------
backgroundConnect3921123213991
firstReactRender22184952235
getState12615418920
initialActions103012
loadScripts102689812437510781175
setupStore116108111025
numNetworkReqs1257017662
BrowserifyPower User HomeuiStartup24621823304726826352985
load1123954159815311451482
domContentLoaded1122954159715411451481
domInteractive11832453104112398
firstPaint------
backgroundConnect922850564110181
firstReactRender84391312197123
getState26558952225354811
initialActions208126
loadScripts1088930155814610981442
setupStore1527779194152642
numNetworkReqs102623036185246
WebpackStandard HomeuiStartup14341278189712514821724
load1217109315199612771420
domContentLoaded1216109315189612771420
domInteractive55251783674139
firstPaint------
backgroundConnect4020151214293
firstReactRender26206562834
getState1165681022
initialActions102012
loadScripts1192104814499012531376
setupStore12666111034
numNetworkReqs1156816661
WebpackPower User HomeuiStartup26442095351830128153193
load13351062185218114061758
domContentLoaded13351062185218114051758
domInteractive10929485109100442
firstPaint------
backgroundConnect942846366108221
firstReactRender82421951991111
getState29182866239487793
initialActions318237
loadScripts12981047173917013181723
setupStore81669410983352
numNetworkReqs100622605880244
📊 Page Load Benchmark Results

Current Commit: 5071d81 | Date: 11/25/2025

📄 Localhost MetaMask Test Dapp

Samples: 100

Summary

  • pageLoadTime-> current mean value: 1.03s (±43ms) 🟡 | historical mean value: 1.03s ⬇️ (historical data)
  • domContentLoaded-> current mean value: 716ms (±39ms) 🟢 | historical mean value: 721ms ⬇️ (historical data)
  • firstContentfulPaint-> current mean value: 76ms (±13ms) 🟢 | historical mean value: 81ms ⬇️ (historical data)

📈 Detailed Results

Metric Mean Std Dev Min Max P95 P99
pageLoadTime 1.03s 43ms 1.01s 1.33s 1.06s 1.33s
domContentLoaded 716ms 39ms 697ms 990ms 736ms 990ms
firstPaint 76ms 13ms 60ms 188ms 84ms 188ms
firstContentfulPaint 76ms 13ms 60ms 188ms 84ms 188ms
largestContentfulPaint 0ms 0ms 0ms 0ms 0ms 0ms
Bundle size diffs [🚨 Warning! Bundle size has increased!]
  • background: 53 Bytes (0%)
  • ui: 965 Bytes (0.01%)
  • common: 91 Bytes (0%)

>
<div className="shield-plan-page__radio" />
{loading && !hasApiError && <LoadingScreen />}
{hasApiError ? (
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Bug: Error UI shows while data is still loading

When a secondary API error occurs (like availableTokenBalancesError) while primary data is still loading (like subscriptionPricingLoading), the error UI displays instead of the loading screen. The error condition should check that loading is complete before showing errors, not display errors during active loading states. This prevents confusing UX where users see an error message while the page is still trying to fetch data in the background.

Fix in Cursor Fix in Web

@metamaskbot
Copy link
Collaborator

Builds ready [e0248ca]
UI Startup Metrics (1243 ± 99 ms)
PlatformBuildTypePageMetricMean (ms)Min (ms)Max (ms)Std Dev (ms)P 75 (ms)P 95 (ms)
ChromeBrowserifyStandard HomeuiStartup1243103014909913001434
load104587912448610861217
domContentLoaded104087512368510811210
domInteractive2714140252197
firstPaint4717612393869721174
backgroundConnect2151992439219233
firstReactRender3319217203548
getState341758113954
initialActions108113
loadScripts8316731037868681001
setupStore1272941320
numNetworkReqs1257821573
BrowserifyPower User HomeuiStartup19191592336228320122516
load100289118321449981357
domContentLoaded98788318231429791341
domInteractive36171783336131
firstPaint6018814143939631290
backgroundConnect22520226514235254
firstReactRender90441552398144
getState16713026028187220
initialActions104112
loadScripts77968516081437651146
setupStore211059112547
numNetworkReqs100632705496263
WebpackStandard HomeuiStartup819693101673863963
load64256381571687781
domContentLoaded63755781170683775
domInteractive2514108212185
firstPaint22382804164203663
backgroundConnect1062751321
firstReactRender26204163136
getState241358103142
initialActions104112
loadScripts63555580969681766
setupStore1063141219
numNetworkReqs1257621574
WebpackPower User HomeuiStartup16221063237423117711950
load6645891183101666934
domContentLoaded6545801176101649929
domInteractive34171522831104
firstPaint25889984175246644
backgroundConnect1584571733
firstReactRender83441081491102
getState14812419515155176
initialActions104112
loadScripts651578116799647920
setupStore23760153653
numNetworkReqs1586438874200374
FirefoxBrowserifyStandard HomeuiStartup12031062157410812611420
load100989712567810531169
domContentLoaded100889712567810521167
domInteractive56291783379130
firstPaint------
backgroundConnect3521203243573
firstReactRender21174452135
getState96689818
initialActions103012
loadScripts98787912387110281141
setupStore13518124935
numNetworkReqs1156615655
BrowserifyPower User HomeuiStartup24151983328725525782910
load1093920155413810871449
domContentLoaded1092918155413810871449
domInteractive11731462102110405
firstPaint------
backgroundConnect902946864104186
firstReactRender884116824103131
getState24655880210307795
initialActions2024327
loadScripts1061902151013110621399
setupStore115674716397518
numNetworkReqs101612966192251
WebpackStandard HomeuiStartup14251230195412214781682
load1202106114498912641381
domContentLoaded1202106114499012641381
domInteractive56262233778117
firstPaint------
backgroundConnect4219221264499
firstReactRender27207082938
getState156138231062
initialActions103012
loadScripts1178102814238512341336
setupStore136175181232
numNetworkReqs1156715656
WebpackPower User HomeuiStartup27572136360530829353297
load13821137198518813881786
domContentLoaded13821137198518813881785
domInteractive10729480100104380
firstPaint------
backgroundConnect1102853779124256
firstReactRender89432212596119
getState30372937234476795
initialActions4159937
loadScripts13391116196417813431745
setupStore1146715160102604
numNetworkReqs101612516077248
📊 Page Load Benchmark Results

Current Commit: e0248ca | Date: 11/25/2025

📄 Localhost MetaMask Test Dapp

Samples: 100

Summary

  • pageLoadTime-> current mean value: 1.05s (±50ms) 🟡 | historical mean value: 1.03s ⬆️ (historical data)
  • domContentLoaded-> current mean value: 731ms (±62ms) 🟢 | historical mean value: 721ms ⬆️ (historical data)
  • firstContentfulPaint-> current mean value: 91ms (±126ms) 🟢 | historical mean value: 81ms ⬆️ (historical data)

📈 Detailed Results

Metric Mean Std Dev Min Max P95 P99
pageLoadTime 1.05s 50ms 1.02s 1.42s 1.06s 1.42s
domContentLoaded 731ms 62ms 701ms 1.28s 746ms 1.28s
firstPaint 91ms 126ms 60ms 1.34s 88ms 1.34s
firstContentfulPaint 91ms 126ms 60ms 1.34s 88ms 1.34s
largestContentfulPaint 0ms 0ms 0ms 0ms 0ms 0ms
Bundle size diffs [🚨 Warning! Bundle size has increased!]
  • background: 970 Bytes (0.02%)
  • ui: 1.99 KiB (0.03%)
  • common: 91 Bytes (0%)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

5 participants