Skip to content

feat(ramps): enforce network access gate in the ramps controller - #47843

Merged
wenfix merged 5 commits into
mainfrom
ramp-basic-functionality
Nov 17, 2026
Merged

wenfix merged 5 commits into
mainfrom
ramp-basic-functionality

Conversation

@wenfix

@wenfix wenfix commented Nov 11, 2026 •

Copy link
Copy Markdown
Contributor

Description

Ramps network access was enforced by wrapping every RampsController network method after construction. That duplicated the policy the UI already needed for order syncing, and wrapping methods made the gate easy to miss whenever the controller grew a new call.

This moves the policy into shared/lib/ramps/network-access.ts, read by the background controller and by ramps order syncing, and hands it to the controller through isNetworkAccessAllowed. The controller no longer calls the ramps API until onboarding is complete and basic functionality is on, and it re-reads that state on every check, so turning basic functionality off takes effect without a restart. The per-method wrapper and its tests are deleted.

Ramps order syncing now runs from RampsBootstrap and lives under ui/hooks/ramps/ instead of ui/hooks/identity/, so money movement owns the whole sync path. It uses the same predicate and layers backup-and-sync on top, which removes the duplicated onboarding check there. Non-production builds also shorten the controller request cache TTL to 60 seconds so a fresh request can be observed while manually testing the gate; production keeps the controller default.

@metamask/ramps-controller@30.0.0 is the release that exposes isNetworkAccessAllowed and requestCacheTTL. A @metamask/ramps-controller@^29.0.0 resolution points the copy used by @metamask/transaction-pay-controller (which still asks for ^29.0.0 until its next bump) at the same version, keeping one copy and dropping the duplicate LavaMoat policy entry.

Changelog

CHANGELOG entry: null

Related issues

Core PR: MetaMask/core#11222
Why now: #47325 (comment)

Manual testing steps

  1. Build the extension, load it, and unlock the wallet with onboarding complete and basic functionality enabled.
  2. Open the ramps buy flow and confirm countries, tokens, and quotes load as before.
  3. Open Settings > Privacy and turn basic functionality off.
  4. Return to the ramps buy flow and confirm ramps stops hydrating and makes no new request, while the rest of the wallet keeps working.
  5. Turn basic functionality back on and confirm the ramps buy flow hydrates again.
  6. On a fresh profile where onboarding is incomplete, confirm the ramps flow never reaches the API.
  7. Start an order, close the extension popup, and confirm order polling continues while the order is in flight.

Screenshots/Recordings

After

ramps-bf-gate-refactor.mp4

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

Medium Risk
Changes how and when ramps hits external APIs based on onboarding and privacy settings; behavior is covered by new tests but regressions would affect buy-flow hydration and order sync.

Overview
Ramps API access is now gated inside @metamask/ramps-controller@30.0.0 via isNetworkAccessAllowed instead of wrapping controller methods after construction. The onboarding + basic-functionality rule lives in shared/lib/ramps/network-access.ts so the background init path and UI stay aligned; ramps-network-gate and its tests are removed.

RampsControllerInit passes a callback that re-reads onboarding and preferences on every check (privacy toggles apply without restart), sets a 60s requestCacheTTL in non-production for easier manual gate testing, and leaves production on the controller default. Order syncing is triggered from RampsBootstrap (not MetamaskIdentityProvider), with useRampsOrderSyncing using the same shared network predicate plus backup-and-sync gates.

Dependency bumps include a resolution so dependents still on ^29.0.0 resolve to 30.0.0, with matching LavaMoat policy updates.

Reviewed by Cursor Bugbot for commit 76ca99a. Bugbot is set up for automated code reviews on this repo. Configure here.

…64538

Pin the preview build that exposes `isNetworkAccessAllowed` and
`requestCacheTTL`, so the host can hand the network gate to the controller
instead of wrapping its methods. Also aligns the copy used by
`@metamask/transaction-pay-controller` on the same version, which drops the
duplicate LavaMoat policy entry.
Ramps network access now comes from a single policy in
`shared/lib/ramps/network-access.ts`, read by both the background and the UI,
instead of a per-method wrapper around the controller. The controller receives
`isNetworkAccessAllowed` and refuses to call the ramps API until onboarding is
complete and basic functionality is on, and it re-reads that state on every
check, so toggling basic functionality off takes effect immediately.

Order syncing uses the same predicate and layers backup-and-sync on top,
which removes the duplicated onboarding check there.

Non-production builds also shorten the controller request cache TTL to 60
seconds so a fresh request can be observed while manually testing the gate.
@wenfix wenfix added the no-changelog no-changelog Indicates no external facing user changes, therefore no changelog documentation needed label Nov 11, 2026
@github-actions

Copy link
Copy Markdown
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.

Naz-Ovh pushed a commit to 0x-fork/metamask-core that referenced this pull request Nov 14, 2026
## Explanation

Adds an optional `isNetworkAllowed` constructor option to
`RampsController` so the host can block RampsController network access
at runtime.

Every method that can reach the network checks the option before any
state write or request, and throws an error carrying the new
`RAMPS_ERROR_CODES.NETWORK_ACCESS_DENIED` code when it returns `false`.
Denied calls do not serve non-expired request-cache entries either, so
hosts render already-fetched data from controller state while access is
denied.

`addOrder`, `addPrecreatedOrder`, `removeOrder`, and `transakLogout`
still apply their local change and skip only the remote call; deferred
order writes are picked up by the next full sync. Order polling pauses
while access is denied without extending its backoff. Omitting the
option keeps the existing behavior.


## References
Client PR: MetaMask/metamask-extension#47843


## Checklist

- [x] I've updated the test suite for new or updated code as appropriate
- [x] I've updated documentation (JSDoc, Markdown, etc.) for new or
updated code as appropriate
- [x] I've communicated my changes to consumers by [updating changelogs
for packages I've
changed](https://github.com/MetaMask/core/tree/main/docs/processes/updating-changelogs.md)
- [ ] I've introduced [breaking
changes](https://github.com/MetaMask/core/tree/main/docs/processes/breaking-changes.md)
in this PR and have prepared draft pull requests for clients and
consumer packages to resolve them

<!-- CURSOR_SUMMARY -->
---

> [!NOTE]
> **Medium Risk**
> Touches many network entry points plus order sync and polling;
incorrect host wiring could block ramps or leave remote state briefly
stale until the next sync, though defaults preserve prior behavior.
> 
> **Overview**
> Adds an optional host-controlled **`isNetworkAccessAllowed`** callback
to `RampsController` so ramps can be blocked from reaching the network
at runtime without changing default behavior when it is omitted.
> 
> **Gated methods** call **`#assertNetworkAccessAllowed()`** up front
(including **`executeRequest`**, so the exposed action cannot bypass the
gate). Denied calls throw with **`errorKey: NETWORK_ACCESS_DENIED`**,
skip messenger/service requests, avoid state writes on reads, and **do
not return cached request results** while denied—UI is expected to read
already-loaded data from controller state.
> 
> **Exceptions** still apply local-only work when denied:
**`addOrder`**, **`addPrecreatedOrder`**, and **`removeOrder`** update
state but defer User Storage incremental sync until the next allowed
**`syncOrdersWithUserStorage`**; **`transakLogout`** clears the local
Transak session without calling the API; order polling **skips refresh**
without advancing error backoff. Full sync aborts queued follow-up
passes if access is revoked mid-sync.
> 
> Docs, changelog, messenger JSDoc, and broad unit tests cover gate
classification, deferred sync, and polling behavior.
> 
> <sup>Reviewed by [Cursor Bugbot](https://cursor.com/bugbot) for commit
1e6f645. Bugbot is set up for automated
code reviews on this repo. Configure
[here](https://www.cursor.com/dashboard/bugbot).</sup>
<!-- /CURSOR_SUMMARY -->
@wenfix wenfix mentioned this pull request Nov 16, 2026
3 tasks done
@metamask-ci

metamask-ci Bot commented Nov 16, 2026 •

Copy link
Copy Markdown
Contributor

✨ Files requiring CODEOWNER review ✨

🔑 @MetaMask/accounts-engineers (2 files, +0 -33)
  • 📁 ui/
    • 📁 contexts/
      • 📁 identity/
        • 📄 index.test.tsx +0 -24
        • 📄 index.tsx +0 -9

👨‍🔧 @MetaMask/money-movement (6 files, +101 -12)
  • 📁 shared/
    • 📁 lib/
      • 📁 ramps/
        • 📄 network-access.test.ts +34 -0
        • 📄 network-access.ts +29 -0
  • 📁 ui/
    • 📁 hooks/
      • 📁 ramps/
        • 📁 useRampsOrderSyncing/
          • 📄 useRampsOrderSyncing.test.tsx +0 -7
          • 📄 useRampsOrderSyncing.ts +6 -3
          • 📄 RampsBootstrap.test.tsx +23 -2
          • 📄 RampsBootstrap.tsx +9 -0

📜 @MetaMask/policy-reviewers (8 files, +16 -8)
  • 📁 lavamoat/
    • 📁 webpack/
      • 📁 mv2/
        • 📁 beta/
          • 📄 policy.json +2 -1
        • 📁 experimental/
          • 📄 policy.json +2 -1
        • 📁 flask/
          • 📄 policy.json +2 -1
        • 📁 main/
          • 📄 policy.json +2 -1
      • 📁 mv3/
        • 📁 beta/
          • 📄 policy.json +2 -1
        • 📁 experimental/
          • 📄 policy.json +2 -1
        • 📁 flask/
          • 📄 policy.json +2 -1
        • 📁 main/
          • 📄 policy.json +2 -1

Tip

Follow the policy review process outlined in the LavaMoat Policy Review Process doc before expecting an approval from Policy Reviewers.

@socket-security

socket-security Bot commented Nov 16, 2026 •

Copy link
Copy Markdown

Review the following changes in direct dependencies. Learn more about Socket for GitHub.

Diff Package Supply Chain
Security
Vulnerability Quality Maintenance License
Updated@​metamask/​ramps-controller@​29.0.0 ⏵ 30.0.09910080 +1100100

View full report

@socket-security

socket-security Bot commented Nov 16, 2026 •

Copy link
Copy Markdown

Caution

MetaMask internal reviewing guidelines:

  • Do not ignore-all
  • Each alert has instructions on how to review if you don't know what it means. If lost, ask your Security Liaison or the supply-chain group
  • Copy-paste ignore lines for specific packages or a group of one kind with a note on what research you did to deem it safe.
    @SocketSecurity ignore npm/PACKAGE@VERSION
Priority Alert  (click "▶" to expand/collapse) Action
Low priority
Potential security risk (AI signal): npm @metamask/ramps-controller is 96.0% likely risky

Notes: The code is an API client and contains no evident malware or obfuscation. A security concern exists in getBuyWidgetUrl: an arbitrary caller-provided URL receives the AuthenticationController bearer token, enabling credential disclosure if that input is untrusted; restrict the destination to trusted origins. Other requests primarily target on-ramp.api.cx.metamask.io, on-ramp-cache.api.cx.metamask.io, the corresponding uat-api.cx.metamask.io and dev-api.cx.metamask.io hosts, or localhost:3000; no suspicious external domain is hardcoded. Severity is moderate to high, conditional on control of buyUrl.

Confidence: 0.96

Severity: 0.72

From: package.json → npm/@metamask/ramps-controller@30.0.0

ℹ Read more on: This package | This alert | What are AI-detected potential security risks?

Next steps: Take a moment to review the security alert above. Review the linked package source code to understand the potential risk. Ensure the package is not malicious before proceeding. If you're unsure how to proceed, reach out to your security team or ask the Socket team for help at support@socket.dev.

Suggestion: An AI system identified potential security problems in this package. It is advised to review the package thoroughly and assess the potential risks before installation. You may also consider reporting the issue to the package maintainer or seeking alternative solutions with a stronger security posture.

Mark the package as acceptable risk. To ignore this alert only in this pull request, reply with the comment @SocketSecurity ignore npm/@metamask/ramps-controller@30.0.0. You can also ignore all packages with @SocketSecurity ignore-all. To ignore an alert for all future pull requests, use Socket's Dashboard to change the triage state of this alert.

Block

View full report

@wenfix
wenfix marked this pull request as ready for review November 16, 2026 16:09
@wenfix
wenfix requested review from a team as code owners November 16, 2026 16:09
@metamask-ci

metamask-ci Bot commented Nov 16, 2026

Copy link
Copy Markdown
Contributor
Builds ready [a3bd8f6]
⚡ Performance Benchmarks (Total: 🟢 6 pass · 🟡 5 warn · 🔴 2 fail)

Baseline (latest main): f693520 | Date: 11/3/2026 | Pipeline: 43903054180 | Baseline logs

Metricschrome-webpackfirefox-webpack
loadNewAccount
[Sentry log · main/release]
🔴 load_new_account(p95) [CI log]🔴 load_new_account(p95) [CI log]

Regressions (🔴 2 failures)

Interaction Benchmarks · Samples: 5 🔴 2
Benchmarkchrome-webpackfirefox-webpack
loadNewAccount
[Sentry log · main/release]
🔴 [CI log]
🔴 load_new_account
🔴 [CI log]
🔴 load_new_account
confirmTx
[Sentry log · main/release]
🟡 [CI log]🟢 [CI log]
bridgeUserActions
[Sentry log · main/release]
🟡 [CI log]🟡 [CI log]
🟡 bridge_load_page
🟡 bridge_search_token

📈 Results compared to the previous 5 runs on main

  • ↑ loadNewAccount/load_new_account: +185%
  • ↑ loadNewAccount/total: +185%
  • ↑ loadNewAccount/inp: +19%
  • ↑ loadNewAccount/fcp: +11%
  • ↑ loadNewAccount/lcp: +988%
  • ↑ loadNewAccount/cls: +572%
  • ↑ confirmTx/longTaskCount: +100%
  • ↑ confirmTx/longTaskTotalDuration: +95%
  • ↑ confirmTx/longTaskMaxDuration: +67%
  • ↑ confirmTx/tbt: +94%
  • ↑ confirmTx/lcp: +1001%
  • ↑ bridgeUserActions/bridge_load_page: +69%
  • ↑ bridgeUserActions/bridge_load_asset_picker: +31%
  • ↑ bridgeUserActions/bridge_search_token: +28%
  • ↑ bridgeUserActions/longTaskCount: +36%
  • ↑ bridgeUserActions/longTaskTotalDuration: +21%
  • ↓ bridgeUserActions/longTaskMaxDuration: -14%
  • ↑ bridgeUserActions/total: +30%
  • ↑ bridgeUserActions/lcp: +961%
  • ↑ bridgeUserActions/cls: +577%
  • ↑ loadNewAccount/load_new_account: +181%
  • ↑ loadNewAccount/total: +181%
  • ↓ loadNewAccount/inp: -10%
  • ↓ loadNewAccount/fcp: -43%
  • ↑ loadNewAccount/lcp: +1033%
  • ↓ confirmTx/longTaskCount: -100%
  • ↓ confirmTx/longTaskTotalDuration: -100%
  • ↓ confirmTx/longTaskMaxDuration: -100%
  • ↓ confirmTx/tbt: -100%
  • ↓ confirmTx/inp: -37%
  • ↓ confirmTx/fcp: -53%
  • ↑ confirmTx/lcp: +1034%
  • ↑ bridgeUserActions/bridge_load_page: +633%
  • ↑ bridgeUserActions/bridge_load_asset_picker: +147%
  • ↑ bridgeUserActions/bridge_search_token: +216%
  • ↓ bridgeUserActions/longTaskCount: -100%
  • ↓ bridgeUserActions/longTaskTotalDuration: -100%
  • ↓ bridgeUserActions/longTaskMaxDuration: -100%
  • ↓ bridgeUserActions/tbt: -100%
  • ↑ bridgeUserActions/total: +261%
  • ↓ bridgeUserActions/inp: -26%
  • ↑ bridgeUserActions/lcp: +1026%

🌐 Core Web Vitals — 🟢 good · 🟡 needs improvement · 🔴 poor (web.dev thresholds)

  • 🟡 loadNewAccount/FCP: p75 1.9s
  • 🟡 confirmTx/FCP: p75 1.9s
  • 🟡 bridgeUserActions/FCP: p75 1.9s
Startup Benchmarks · Samples: 100
Benchmarkchrome-webpackfirefox-webpack
startupStandardHome
[Sentry log · main/release]
🟢 [CI log]🟡 [CI log]
🟡 loadScripts

📈 Results compared to the previous 5 runs on main

  • ↓ startupStandardHome/uiStartup: -17%
  • ↓ startupStandardHome/domInteractive: -19%
  • ↓ startupStandardHome/firstPaint: -50%
  • ↓ startupStandardHome/backgroundConnect: -23%
  • ↓ startupStandardHome/firstReactRender: -47%
  • ↓ startupStandardHome/initialActions: -64%
  • ↑ startupStandardHome/setupStore: +62%
  • ↑ startupStandardHome/longTaskMaxDuration: +12%
  • ↓ startupStandardHome/inp: -37%
  • ↑ startupStandardHome/lcp: +355%
  • ↓ startupStandardHome/cls: -72%
  • ↑ startupStandardHome/domInteractive: +46%
  • ↑ startupStandardHome/firstReactRender: +15%
  • ↓ startupStandardHome/initialActions: -50%
  • ↓ startupStandardHome/setupStore: -14%
  • ↑ startupStandardHome/fcp: +48%
User Journey Benchmarks · Samples: 5 · mock API
Benchmarkchrome-webpackfirefox-webpack
onboardingImportWallet
[Sentry log · main/release]
🟢 [CI log]🟡 [CI log]
🟡 total
onboardingNewWallet
[Sentry log · main/release]
🟢 [CI log]🟢 [CI log]

📈 Results compared to the previous 5 runs on main

  • ↓ onboardingImportWallet/srpButtonToSrpForm: -11%
  • ↓ onboardingImportWallet/metricsToWalletReadyScreen: -20%
  • ↓ onboardingImportWallet/doneButtonToHomeScreen: -94%
  • ↓ onboardingImportWallet/openAccountMenuToAccountListLoaded: -74%
  • ↓ onboardingImportWallet/longTaskCount: -100%
  • ↓ onboardingImportWallet/longTaskTotalDuration: -100%
  • ↓ onboardingImportWallet/longTaskMaxDuration: -100%
  • ↓ onboardingImportWallet/tbt: -100%
  • ↓ onboardingImportWallet/total: -87%
  • ↑ onboardingNewWallet/srpButtonToPwForm: +31%
  • ↑ onboardingNewWallet/createPwToRecoveryScreen: +39%
  • ↑ onboardingNewWallet/skipBackupToMetricsScreen: +20%
  • ↑ onboardingNewWallet/agreeButtonToOnboardingSuccess: +13%
  • ↓ onboardingNewWallet/doneButtonToAssetList: -72%
  • ↓ onboardingNewWallet/longTaskCount: -62%
  • ↓ onboardingNewWallet/longTaskTotalDuration: -100%
  • ↓ onboardingNewWallet/longTaskMaxDuration: -29%
  • ↓ onboardingNewWallet/tbt: -100%
  • ↓ onboardingNewWallet/total: -68%
Dapp Page Load Benchmarks · Samples: 100
Benchmarkchrome-webpack
dappPageLoad
[Sentry log · main/release]
🟢 [CI log]

📈 Results compared to the previous 5 runs on main

  • ↓ dappPageLoad/pageLoadTime: -49%
  • ↓ dappPageLoad/firstPaint: -28%
  • ↓ dappPageLoad/firstContentfulPaint: -28%
Bundle Size Diffs [🚨 Warning! Bundle size has increased!]
Status Bundle Total Diff Change
✅ background 15.22 MiB -1.08 KiB -0.01%
🚨 ui 19.6 MiB +13.03 KiB +0.06%
✅ common 0 Bytes 0 Bytes 0.00%
✅ other 4.46 MiB +145 Bytes 0.00%
✅ content scripts 3.2 MiB +290 Bytes +0.01%
🚨 unzipped 79.99 MiB +12.38 KiB +0.02%
🚨 zip 24.05 MiB +3.28 KiB +0.01%

@wenfix

wenfix commented Nov 16, 2026

Copy link
Copy Markdown
Contributor Author

@SocketSecurity ignore @metamask/ramps-controller

The issue flagged is already present in the previous version and a fix is in the works.

@wenfix
wenfix enabled auto-merge November 16, 2026 16:34
mcmire
mcmire previously approved these changes Nov 16, 2026

@mcmire mcmire left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Policy changes look OK.

gantunesr
gantunesr previously approved these changes Nov 17, 2026
meltingice1337
meltingice1337 previously approved these changes Nov 17, 2026
@metamask-ci

metamask-ci Bot commented Nov 17, 2026

Copy link
Copy Markdown
Contributor
Builds ready [76ca99a]
⚡ Performance Benchmarks (Total: 🟢 5 pass · 🟡 6 warn · 🔴 2 fail)

Baseline (latest main): f693520 | Date: 11/3/2026 | Pipeline: 44098895305 | Baseline logs

Metricschrome-webpackfirefox-webpack
loadNewAccount
[Sentry log · main/release]
🔴 load_new_account(p95) [CI log]🔴 load_new_account(p95) [CI log]

Regressions (🔴 2 failures)

Interaction Benchmarks · Samples: 5 🔴 2
Benchmarkchrome-webpackfirefox-webpack
loadNewAccount
[Sentry log · main/release]
🔴 [CI log]
🔴 load_new_account
🔴 [CI log]
🔴 load_new_account
confirmTx
[Sentry log · main/release]
🟡 [CI log]🟢 [CI log]
bridgeUserActions
[Sentry log · main/release]
🟡 [CI log]🟡 [CI log]
🟡 bridge_load_page
🟡 bridge_load_asset_picker
🟡 bridge_search_token

📈 Results compared to the previous 5 runs on main

  • ↑ loadNewAccount/load_new_account: +184%
  • ↑ loadNewAccount/total: +184%
  • ↑ loadNewAccount/inp: +19%
  • ↑ loadNewAccount/lcp: +934%
  • ↑ loadNewAccount/cls: +572%
  • ↑ confirmTx/longTaskCount: +67%
  • ↑ confirmTx/longTaskTotalDuration: +77%
  • ↑ confirmTx/longTaskMaxDuration: +68%
  • ↑ confirmTx/tbt: +88%
  • ↓ confirmTx/inp: -21%
  • ↑ confirmTx/lcp: +971%
  • ↑ bridgeUserActions/bridge_load_page: +51%
  • ↑ bridgeUserActions/bridge_load_asset_picker: +39%
  • ↑ bridgeUserActions/bridge_search_token: +34%
  • ↑ bridgeUserActions/longTaskCount: +36%
  • ↑ bridgeUserActions/longTaskTotalDuration: +35%
  • ↑ bridgeUserActions/tbt: +35%
  • ↑ bridgeUserActions/total: +35%
  • ↑ bridgeUserActions/inp: +10%
  • ↑ bridgeUserActions/lcp: +984%
  • ↓ bridgeUserActions/cls: -86%
  • ↑ loadNewAccount/load_new_account: +180%
  • ↑ loadNewAccount/total: +180%
  • ↓ loadNewAccount/inp: -25%
  • ↓ loadNewAccount/fcp: -54%
  • ↑ loadNewAccount/lcp: +1055%
  • ↓ confirmTx/longTaskCount: -100%
  • ↓ confirmTx/longTaskTotalDuration: -100%
  • ↓ confirmTx/longTaskMaxDuration: -100%
  • ↓ confirmTx/tbt: -100%
  • ↓ confirmTx/inp: -37%
  • ↓ confirmTx/fcp: -59%
  • ↑ confirmTx/lcp: +1042%
  • ↑ bridgeUserActions/bridge_load_page: +541%
  • ↑ bridgeUserActions/bridge_load_asset_picker: +459%
  • ↑ bridgeUserActions/bridge_search_token: +198%
  • ↓ bridgeUserActions/longTaskCount: -100%
  • ↓ bridgeUserActions/longTaskTotalDuration: -100%
  • ↓ bridgeUserActions/longTaskMaxDuration: -100%
  • ↓ bridgeUserActions/tbt: -100%
  • ↑ bridgeUserActions/total: +249%
  • ↑ bridgeUserActions/inp: +91%
  • ↓ bridgeUserActions/fcp: -63%
  • ↑ bridgeUserActions/lcp: +1040%

🌐 Core Web Vitals — 🟢 good · 🟡 needs improvement · 🔴 poor (web.dev thresholds)

  • 🟡 loadNewAccount/FCP: p75 1.8s
  • 🟡 confirmTx/FCP: p75 1.8s
  • 🟡 bridgeUserActions/FCP: p75 1.9s
  • 🟡 bridgeUserActions/INP: p75 208ms
Startup Benchmarks · Samples: 100
Benchmarkchrome-webpackfirefox-webpack
startupStandardHome
[Sentry log · main/release]
🟢 [CI log]🟡 [CI log]
🟡 loadScripts

📈 Results compared to the previous 5 runs on main

  • ↑ startupStandardHome/load: +29%
  • ↑ startupStandardHome/domContentLoaded: +29%
  • ↓ startupStandardHome/firstPaint: -55%
  • ↓ startupStandardHome/firstReactRender: -29%
  • ↓ startupStandardHome/initialActions: -64%
  • ↑ startupStandardHome/loadScripts: +27%
  • ↑ startupStandardHome/setupStore: +95%
  • ↑ startupStandardHome/longTaskCount: +43%
  • ↑ startupStandardHome/longTaskTotalDuration: +19%
  • ↑ startupStandardHome/longTaskMaxDuration: +34%
  • ↑ startupStandardHome/tbt: +20%
  • ↓ startupStandardHome/fcp: -65%
  • ↑ startupStandardHome/lcp: +56%
  • ↓ startupStandardHome/cls: -72%
  • ↑ startupStandardHome/domInteractive: +41%
  • ↑ startupStandardHome/backgroundConnect: +12%
  • ↑ startupStandardHome/firstReactRender: +29%
  • ↓ startupStandardHome/initialActions: -50%
  • ↑ startupStandardHome/fcp: +36%
User Journey Benchmarks · Samples: 5 · mock API
Benchmarkchrome-webpackfirefox-webpack
onboardingImportWallet
[Sentry log · main/release]
🟢 [CI log]🟡 [CI log]
🟡 total
onboardingNewWallet
[Sentry log · main/release]
🟢 [CI log]🟡 [CI log]
🟡 total

📈 Results compared to the previous 5 runs on main

  • ↑ onboardingImportWallet/srpButtonToSrpForm: +29%
  • ↑ onboardingImportWallet/confirmSrpToPwForm: +36%
  • ↑ onboardingImportWallet/pwFormToMetricsScreen: +41%
  • ↑ onboardingImportWallet/metricsToWalletReadyScreen: +44%
  • ↓ onboardingImportWallet/doneButtonToHomeScreen: -93%
  • ↓ onboardingImportWallet/openAccountMenuToAccountListLoaded: -74%
  • ↓ onboardingImportWallet/longTaskCount: -100%
  • ↓ onboardingImportWallet/longTaskTotalDuration: -100%
  • ↓ onboardingImportWallet/longTaskMaxDuration: -100%
  • ↓ onboardingImportWallet/tbt: -100%
  • ↓ onboardingImportWallet/total: -86%
  • ↑ onboardingNewWallet/srpButtonToPwForm: +12%
  • ↑ onboardingNewWallet/createPwToRecoveryScreen: +32%
  • ↑ onboardingNewWallet/skipBackupToMetricsScreen: +16%
  • ↓ onboardingNewWallet/doneButtonToAssetList: -73%
  • ↓ onboardingNewWallet/longTaskCount: -62%
  • ↓ onboardingNewWallet/longTaskTotalDuration: -72%
  • ↓ onboardingNewWallet/longTaskMaxDuration: -34%
  • ↓ onboardingNewWallet/tbt: -100%
  • ↓ onboardingNewWallet/total: -69%
Dapp Page Load Benchmarks · Samples: 100
Benchmarkchrome-webpack
dappPageLoad
[Sentry log · main/release]
🟢 [CI log]

📈 Results compared to the previous 5 runs on main

  • ↓ dappPageLoad/pageLoadTime: -67%
  • ↓ dappPageLoad/domContentLoaded: -33%
  • ↓ dappPageLoad/firstPaint: -52%
  • ↓ dappPageLoad/firstContentfulPaint: -52%
Bundle Size Diffs [🚀 Bundle size reduced!]
Status Bundle Total Diff Change
✅ background 15.16 MiB -55.71 KiB -0.36%
✅ ui 19.17 MiB -423.07 KiB -2.11%
✅ common 0 Bytes 0 Bytes 0.00%
✅ other 4.46 MiB -7.31 KiB -0.16%
✅ content scripts 3.19 MiB -14.51 KiB -0.44%
✅ unzipped 79.49 MiB -507.12 KiB -0.62%
✅ zip 23.92 MiB -127.41 KiB -0.52%

@mcmire mcmire left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

LGTM.

@wenfix

wenfix commented Nov 17, 2026

Copy link
Copy Markdown
Contributor Author

@SocketSecurity ignore @metamask/ramps-controller

The issue flagged is already present in the previous version and a fix is in the works.

@sonarqubecloud

Copy link
Copy Markdown

Quality Gate Passed Quality Gate passed

Issues
0 New issues
0 Accepted issues

Measures
0 Security Hotspots
97.2% Coverage on New Code
0.0% Duplication on New Code

See analysis details on SonarQube Cloud

@wenfix
wenfix added this pull request to the merge queue Nov 17, 2026
Merged via the queue into main with commit dcae2a1 Nov 17, 2026
256 of 264 checks passed
@wenfix
wenfix deleted the ramp-basic-functionality branch November 17, 2026 19:14
@github-actions github-actions Bot locked and limited conversation to collaborators Nov 17, 2026

This branch was previously deployed

1 inactive deployment
pr-comment — 76ca99a4 Deployed Nov 17, 2026 by wenfix via Publish prerelease / Publish prerelease #175176
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

no-changelog no-changelog Indicates no external facing user changes, therefore no changelog documentation needed size-M team-money-movement

Projects

None yet

Development

Successfully merging this pull request may close these issues.

5 participants