Skip to content

Conversation

@sophieqgu
Copy link
Contributor

@sophieqgu sophieqgu commented Nov 14, 2025

Description

https://consensyssoftware.atlassian.net/browse/RWDS-268
Part 2 of #36827 pertaining to metametrics changes

Open in GitHub Codespaces

Changelog

CHANGELOG entry: null

Related issues

Fixes:

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

Expose a MetaMetrics traits update API and add rewards-specific traits, events, and category constants.

  • MetaMetrics:
    • Expose updateMetaMetricsTraits via getApi() in app/scripts/metamask-controller.js (binds to metaMetricsController.updateTraits).
    • Extend rewards-related tracking in shared/constants/metametrics.ts:
      • Add user traits: has_rewards_opted_in, rewards_referred, rewards_referral_code_used and corresponding MetaMetricsUserTrait enums.
      • Add event names for rewards flows: REWARDS_OPT_IN_* and REWARDS_ACCOUNT_LINKING_*.
      • Add Rewards to MetaMetricsEventCategory.

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

@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 metamaskbot added the team-rewards Rewards team label Nov 14, 2025
@metamaskbot
Copy link
Collaborator

Builds ready [9773647]
UI Startup Metrics (1224 ± 84 ms)
PlatformBuildTypePageMetricMean (ms)Min (ms)Max (ms)Std Dev (ms)P 75 (ms)P 95 (ms)
ChromeBrowserifyStandard HomeuiStartup1224107214878412801349
load106193312617711161188
domContentLoaded105592912587511101175
domInteractive221585161870
firstPaint60691122241710701162
backgroundConnect2322182648235248
firstReactRender29205473144
getState2074382636
initialActions104113
loadScripts829673102475884946
setupStore1172541120
numNetworkReqs1367519671
BrowserifyPower User HomeuiStartup22081889264122423902641
load11481012153117613361531
domContentLoaded1128991152217913241522
domInteractive592120756118207
firstPaint645207154249511641542
backgroundConnect25323228213257282
firstReactRender74471031788103
getState24518439660283396
initialActions103123
loadScripts897761128617410871286
setupStore281471123271
numNetworkReqs1259119834158198
WebpackStandard HomeuiStartup86672512121028731181
load62957096478627854
domContentLoaded62156594376618841
domInteractive1912107171565
firstPaint23660944234212784
backgroundConnect251066122857
firstReactRender3520275263857
getState1173431216
initialActions101011
loadScripts61856393274616831
setupStore1263341418
numNetworkReqs1367519670
WebpackPower User HomeuiStartup1097905169327214361693
load67857610041577921004
domContentLoaded661566966146773966
domInteractive321390328190
firstPaint38898945295600945
backgroundConnect611719461108194
firstReactRender40374424044
getState1357416124149161
initialActions101011
loadScripts656564953142762953
setupStore146102239102
numNetworkReqs836413025119130
FirefoxBrowserifyStandard HomeuiStartup15171338225413315591795
load1270115015218213121458
domContentLoaded1270115015208213121458
domInteractive54342543946154
firstPaint------
backgroundConnect4324176204968
firstReactRender28235352942
getState1273951221
initialActions204123
loadScripts1244113514587712831424
setupStore188230301453
numNetworkReqs1266716859
BrowserifyPower User HomeuiStartup32922513450964241134509
load14741233178918717101789
domContentLoaded14741233178918717101789
domInteractive22564540156388540
firstPaint------
backgroundConnect5758013313859261331
firstReactRender89611221697122
getState1489327544183275
initialActions317137
loadScripts14301207174118216171741
setupStore913218341130183
numNetworkReqs1267823862226238
WebpackStandard HomeuiStartup16561475214413716912016
load13971243171610514431644
domContentLoaded13971241171510514431643
domInteractive54301542662116
firstPaint------
backgroundConnect52241322458111
firstReactRender342588103745
getState14758111251
initialActions203123
loadScripts1364121616269814131599
setupStore187152231371
numNetworkReqs1366917766
WebpackPower User HomeuiStartup31812563424251435874242
load16341408202617918112026
domContentLoaded16341408202617918112026
domInteractive20860625171364625
firstPaint------
backgroundConnect463143904272830904
firstReactRender956612817110128
getState15710429946162299
initialActions217137
loadScripts15891354199918417871999
setupStore1013340886116408
numNetworkReqs1277822045183220
📊 Page Load Benchmark Results

Current Commit: 9773647 | Date: 11/14/2025

📄 Localhost MetaMask Test Dapp

Samples: 100

Summary

  • pageLoadTime-> current mean value: 1.03s (±49ms) 🟡 | historical mean value: 1.03s ⬇️ (historical data)
  • domContentLoaded-> current mean value: 720ms (±66ms) 🟢 | historical mean value: 718ms ⬆️ (historical data)
  • firstContentfulPaint-> current mean value: 89ms (±126ms) 🟢 | historical mean value: 77ms ⬆️ (historical data)

📈 Detailed Results

Metric Mean Std Dev Min Max P95 P99
pageLoadTime 1.03s 49ms 1.00s 1.32s 1.05s 1.32s
domContentLoaded 720ms 66ms 693ms 1.25s 737ms 1.25s
firstPaint 89ms 126ms 56ms 1.32s 84ms 1.32s
firstContentfulPaint 89ms 126ms 56ms 1.32s 84ms 1.32s
largestContentfulPaint 0ms 0ms 0ms 0ms 0ms 0ms
Bundle size diffs [🚨 Warning! Bundle size has increased!]
  • background: 105 Bytes (0%)
  • ui: 0 Bytes (0%)
  • common: 515 Bytes (0.01%)

@sophieqgu sophieqgu enabled auto-merge November 14, 2025 20:17
@sophieqgu sophieqgu added this pull request to the merge queue Nov 17, 2025
Merged via the queue into main with commit 7d89d43 Nov 17, 2025
184 of 185 checks passed
@sophieqgu sophieqgu deleted the onboarding-tour-metametrics branch November 17, 2025 11:17
@github-actions github-actions bot locked and limited conversation to collaborators Nov 17, 2025
@metamaskbot metamaskbot added the release-13.11.0 Issue or pull request that will be included in release 13.11.0 label Nov 17, 2025
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

release-13.11.0 Issue or pull request that will be included in release 13.11.0 size-S team-rewards Rewards team

Projects

None yet

Development

Successfully merging this pull request may close these issues.

5 participants