Skip to content

Conversation

micaelae
Copy link
Member

@micaelae micaelae commented Sep 25, 2025

Description

Changes

  • Bump bridge controllers to 47.0.0 (fix: read selectedAccount from quote request and submitTx args core#6719) to remove dependency on the selectedAccountId when fetching quotes and submitting a transaction
  • Add controller permissions for getAccountByAddress action
  • Add selected account address to submitTx call params
  • Updates solana activity selectors so all tx submitted by accountGroup are visible

Open in GitHub Codespaces

Changelog

CHANGELOG entry: fix: include accountAddress in swap tx submission params and show bridge activity list items for all accounts in accountGroup

Related issues

Fixes: https://consensyssoftware.atlassian.net/browse/MUL-983

Manual testing steps

  1. Submit solana swap tx
  2. Submit solana bridge tx
  3. Submit evm swap tx
  4. Submit evm bridge tx
  5. balances shown in Swap page should be accurate
  6. CTA button should be disabled when account has insufficient balance
  7. submission should succeed if user has enough funds
  8. transactions should be sent from expected accounts
  9. all transactions should be visible in activity log (both EVM and Solana)

Screenshots/Recordings

Before

Nothing happens after attempting to submit a solana transaction. Old solana bridge txs don't appear in activity list

After

Able to submit a solana tx, and can see old and new solana bridge transactions

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.

@metamaskbot metamaskbot added the team-swaps-and-bridge Swaps and Bridge team label Sep 25, 2025
@micaelae micaelae changed the base branch from main to swap3098-sol-balance September 25, 2025 00:22
@metamaskbot
Copy link
Collaborator

metamaskbot commented Sep 25, 2025

✨ Files requiring CODEOWNER review ✨

🔄 @MetaMask/swaps-engineers (7 files, +102 -49)
  • 📁 ui/
    • 📁 ducks/
      • 📁 bridge/
        • 📄 bridge.test.ts +2 -0
      • 📁 bridge-status/
        • 📄 actions.ts +8 -2
        • 📄 selectors.ts +33 -14
    • 📁 hooks/
      • 📁 bridge/
        • 📄 useSolanaBridgeTransactionMapping.ts +2 -2
    • 📁 pages/
      • 📁 bridge/
        • 📁 hooks/
          • 📁 __snapshots__/
            • 📄 useSubmitBridgeTransaction.test.tsx.snap +2 -0
            • 📄 useSubmitBridgeTransaction.ts +15 -2
        • 📁 prepare/
          • 📄 prepare-bridge-page.tsx +40 -29

Base automatically changed from swap3098-sol-balance to main September 25, 2025 19:04
micaelae added a commit to MetaMask/core that referenced this pull request Sep 25, 2025
## Explanation

This change replaces `getSelectedMultichainAccount` calls with
`getAccountByAddress(walletAddress)`, which mitigates tx submission
issues that happen when the selected account is different from the
account for which the quotes were fetched

Note that there are breaking changes (see changelogs) in the `submitTx`
and `updateBridgeQuoteParams` handlers.

Extension integration PR:
MetaMask/metamask-extension#36321

<!--
Thanks for your contribution! Take a moment to answer these questions so
that reviewers have the information they need to properly understand
your changes:

* What is the current state of things and why does it need to change?
* What is the solution your changes offer and how does it work?
* Are there any changes whose purpose might not obvious to those
unfamiliar with the domain?
* If your primary goal was to update one package but you found you had
to update another one along the way, why did you do so?
* If you had to upgrade a dependency, why did you do so?
-->

## References

Fixes https://consensyssoftware.atlassian.net/browse/MUL-983

<!--
Are there any issues that this pull request is tied to?
Are there other links that reviewers should consult to understand these
changes better?
Are there client or consumer pull requests to adopt any breaking
changes?

For example:

* Fixes #12345
* Related to #67890
-->

## 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/contributing.md#updating-changelogs),
highlighting breaking changes as necessary
- [x] I've prepared draft pull requests for clients and consumer
packages to resolve any breaking changes
Copy link

socket-security bot commented Sep 25, 2025

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

Diff Package Supply Chain
Security
Vulnerability Quality Maintenance License
Updated@​metamask/​bridge-status-controller@​46.0.0 ⏵ 47.0.099 +110078 +198100
Updated@​metamask/​bridge-controller@​46.0.0 ⏵ 47.0.099 +110078 +198100
Updated@​metamask/​utils@​11.8.0 ⏵ 11.8.1991009496 +2100

View full report

@metamaskbot
Copy link
Collaborator

📊 Page Load Benchmark Results

Current Commit: 6ce5e62 | Date: 9/25/2025

📄 Localhost MetaMask Test Dapp

Samples: 100

Summary

  • pageLoadTime-> current mean value: 1.10s (±78ms) 🟡 | historical mean value: 1.05s ⬆️ (historical data)
  • domContentLoaded-> current mean value: 772ms (±75ms) 🟢 | historical mean value: 736ms ⬆️ (historical data)
  • firstContentfulPaint-> current mean value: 81ms (±11ms) 🟢 | historical mean value: 79ms ⬆️ (historical data)
📈 Detailed Results
Metric Mean Std Dev Min Max P95 P99
pageLoadTime 1.10s 78ms 1.05s 1.40s 1.33s 1.40s
domContentLoaded 772ms 75ms 734ms 1.07s 995ms 1.07s
firstPaint 81ms 11ms 64ms 180ms 92ms 180ms
firstContentfulPaint 81ms 11ms 64ms 180ms 92ms 180ms
largestContentfulPaint 0ms 0ms 0ms 0ms 0ms 0ms

Results generated automatically by MetaMask CI

@metamaskbot
Copy link
Collaborator

Builds ready [6ce5e62]
UI Startup Metrics (1252 ± 60 ms)
PlatformBuildTypePageMetricMean (ms)Min (ms)Max (ms)Std Dev (ms)P 75 (ms)P 95 (ms)
ChromeBrowserifyHomeuiStartup1252114013966012871367
load108197812345311131174
domContentLoaded107497212275311071167
domInteractive18134661736
firstPaint633103122043910861168
backgroundConnect2552423019259269
firstReactRender26175672839
getState1464271628
initialActions60699619
loadScripts82573497552860927
setupStore952231017
WebpackHomeuiStartup1185949144211112661328
load990774125210510591132
domContentLoaded985770124810510561129
domInteractive171358101547
firstPaint1486736153181245
backgroundConnect16113361730
firstReactRender37345033743
getState74193713
initialActions62164814
loadScripts982768124610510531126
setupStore96263913
FirefoxBrowserifyHomeuiStartup1409122917979514531601
load1217107913496412731316
domContentLoaded1217107913486412731315
domInteractive1023428451110241
firstPaintNaNNaNNaNNaNNaNNaN
backgroundConnect3219147183357
firstReactRender29247772941
getState63435612
initialActions6118218412
loadScripts1192106213306312541296
setupStore15520128953
WebpackHomeuiStartup15671350227618116352061
load13281148169113014121609
domContentLoaded13281148169113014121608
domInteractive1083238069101303
firstPaintNaNNaNNaNNaNNaNNaN
backgroundConnect3420207233679
firstReactRender37305143946
getState6278769
initialActions3022348
loadScripts13041132167012713931557
setupStore105698918
Benchmark value 1252 exceeds gate value 1234 for chrome browserify home mean uiStartup
Benchmark value 1081 exceeds gate value 1070 for chrome browserify home mean load
Benchmark value 1075 exceeds gate value 1061 for chrome browserify home mean domContentLoaded
Benchmark value 256 exceeds gate value 10 for chrome browserify home mean backgroundConnect
Benchmark value 26 exceeds gate value 23 for chrome browserify home mean firstReactRender
Benchmark value 7 exceeds gate value 1 for chrome browserify home mean initialActions
Benchmark value 1367 exceeds gate value 1365 for chrome browserify home p95 uiStartup
Benchmark value 270 exceeds gate value 18 for chrome browserify home p95 backgroundConnect
Benchmark value 19 exceeds gate value 1.2 for chrome browserify home p95 initialActions
Benchmark value 14 exceeds gate value 7 for chrome webpack home p95 initialActions
Benchmark value 1409 exceeds gate value 1405 for firefox browserify home mean uiStartup
Benchmark value 32 exceeds gate value 25 for firefox browserify home mean backgroundConnect
Benchmark value 29 exceeds gate value 25 for firefox browserify home mean firstReactRender
Benchmark value 6 exceeds gate value 1 for firefox browserify home mean initialActions
Benchmark value 16 exceeds gate value 9 for firefox browserify home mean setupStore
Benchmark value 241 exceeds gate value 195 for firefox browserify home p95 domInteractive
Benchmark value 12 exceeds gate value 2 for firefox browserify home p95 initialActions
Benchmark value 53 exceeds gate value 27 for firefox browserify home p95 setupStore
Benchmark value 108 exceeds gate value 100 for firefox webpack home mean domInteractive
Benchmark value 35 exceeds gate value 26 for firefox webpack home mean backgroundConnect
Benchmark value 4 exceeds gate value 1 for firefox webpack home mean initialActions
Benchmark value 2061 exceeds gate value 1935 for firefox webpack home p95 uiStartup
Benchmark value 303 exceeds gate value 156 for firefox webpack home p95 domInteractive
Benchmark value 79 exceeds gate value 49 for firefox webpack home p95 backgroundConnect
Benchmark value 8 exceeds gate value 2 for firefox webpack home p95 initialActions
Sum of mean exceeds: 345ms | Sum of p95 exceeds: 669.8ms
Sum of all benchmark exceeds: 1014.8ms

Bundle size diffs [🚨 Warning! Bundle size has increased!]
  • background: 2.99 KiB (0.07%)
  • ui: -116 Bytes (0%)
  • common: 1.96 KiB (0.03%)

@micaelae micaelae changed the title fix: Solana bridge tx submission and activity list items fix: Solana swap tx submission and activity list items Sep 25, 2025
@micaelae micaelae marked this pull request as ready for review September 25, 2025 23:34
@micaelae micaelae requested a review from a team as a code owner September 25, 2025 23:34
@metamaskbot
Copy link
Collaborator

📊 Page Load Benchmark Results

Current Commit: d8c4d4e | Date: 9/25/2025

📄 Localhost MetaMask Test Dapp

Samples: 100

Summary

  • pageLoadTime-> current mean value: 1.06s (±71ms) 🟡 | historical mean value: 1.05s ⬆️ (historical data)
  • domContentLoaded-> current mean value: 741ms (±68ms) 🟢 | historical mean value: 736ms ⬆️ (historical data)
  • firstContentfulPaint-> current mean value: 78ms (±12ms) 🟢 | historical mean value: 79ms ⬇️ (historical data)
📈 Detailed Results
Metric Mean Std Dev Min Max P95 P99
pageLoadTime 1.06s 71ms 1.02s 1.32s 1.28s 1.32s
domContentLoaded 741ms 68ms 706ms 998ms 956ms 998ms
firstPaint 78ms 12ms 60ms 180ms 92ms 180ms
firstContentfulPaint 78ms 12ms 60ms 180ms 92ms 180ms
largestContentfulPaint 0ms 0ms 0ms 0ms 0ms 0ms

Results generated automatically by MetaMask CI

@metamaskbot
Copy link
Collaborator

Builds ready [d8c4d4e]
UI Startup Metrics (1232 ± 58 ms)
PlatformBuildTypePageMetricMean (ms)Min (ms)Max (ms)Std Dev (ms)P 75 (ms)P 95 (ms)
ChromeBrowserifyHomeuiStartup1232112014285812661318
load106696911925311041152
domContentLoaded105996311875310981145
domInteractive191359101745
firstPaint68173120042810751151
backgroundConnect2542432706258266
firstReactRender25174262737
getState1253661526
initialActions41173512
loadScripts81271893551846896
setupStore951821013
WebpackHomeuiStartup1165925144611112381308
load978758127110610421128
domContentLoaded974753126810610391124
domInteractive16126691441
firstPaint1526231551179243
backgroundConnect1693061728
firstReactRender36335133644
getState73263712
initialActions82869815
loadScripts971751126510510341122
setupStore86132912
FirefoxBrowserifyHomeuiStartup1450125818819614921605
load1255109714407013011373
domContentLoaded1255109614407013011373
domInteractive1043431451114249
firstPaintNaNNaNNaNNaNNaNNaN
backgroundConnect3622136193785
firstReactRender29245653034
getState62334712
initialActions51638410
loadScripts1228107814137012791332
setupStore12515418950
WebpackHomeuiStartup15481372211116316391891
load13201160173215114121621
domContentLoaded13201160173115114121621
domInteractive108333337097294
firstPaintNaNNaNNaNNaNNaNNaN
backgroundConnect32215173842
firstReactRender37316243941
getState63172610
initialActions401481547
loadScripts12961131171315313911600
setupStore952931017
Benchmark value 254 exceeds gate value 10 for chrome browserify home mean backgroundConnect
Benchmark value 25 exceeds gate value 23 for chrome browserify home mean firstReactRender
Benchmark value 5 exceeds gate value 1 for chrome browserify home mean initialActions
Benchmark value 45 exceeds gate value 41 for chrome browserify home p95 domInteractive
Benchmark value 266 exceeds gate value 18 for chrome browserify home p95 backgroundConnect
Benchmark value 12 exceeds gate value 1.2 for chrome browserify home p95 initialActions
Benchmark value 8 exceeds gate value 7 for chrome webpack home mean initialActions
Benchmark value 15 exceeds gate value 7 for chrome webpack home p95 initialActions
Benchmark value 1450 exceeds gate value 1405 for firefox browserify home mean uiStartup
Benchmark value 1256 exceeds gate value 1245 for firefox browserify home mean load
Benchmark value 1255 exceeds gate value 1239 for firefox browserify home mean domContentLoaded
Benchmark value 36 exceeds gate value 25 for firefox browserify home mean backgroundConnect
Benchmark value 29 exceeds gate value 25 for firefox browserify home mean firstReactRender
Benchmark value 5 exceeds gate value 1 for firefox browserify home mean initialActions
Benchmark value 13 exceeds gate value 9 for firefox browserify home mean setupStore
Benchmark value 249 exceeds gate value 195 for firefox browserify home p95 domInteractive
Benchmark value 85 exceeds gate value 70 for firefox browserify home p95 backgroundConnect
Benchmark value 10 exceeds gate value 2 for firefox browserify home p95 initialActions
Benchmark value 50 exceeds gate value 27 for firefox browserify home p95 setupStore
Benchmark value 108 exceeds gate value 100 for firefox webpack home mean domInteractive
Benchmark value 32 exceeds gate value 26 for firefox webpack home mean backgroundConnect
Benchmark value 5 exceeds gate value 1 for firefox webpack home mean initialActions
Benchmark value 294 exceeds gate value 156 for firefox webpack home p95 domInteractive
Benchmark value 7 exceeds gate value 2 for firefox webpack home p95 initialActions
Sum of mean exceeds: 364ms | Sum of p95 exceeds: 513.8ms
Sum of all benchmark exceeds: 877.8ms

Bundle size diffs [🚨 Warning! Bundle size has increased!]
  • background: 2.99 KiB (0.07%)
  • ui: -116 Bytes (0%)
  • common: 1.96 KiB (0.03%)

@ngalee8311
Copy link

mul983-solana-activity
files changed

@micaelae micaelae added this pull request to the merge queue Sep 26, 2025
@github-merge-queue github-merge-queue bot removed this pull request from the merge queue due to failed status checks Sep 26, 2025
@micaelae micaelae added this pull request to the merge queue Sep 26, 2025
Merged via the queue into main with commit 31742a1 Sep 26, 2025
158 of 162 checks passed
@micaelae micaelae deleted the mul983-solana-activity branch September 26, 2025 20:45
@github-actions github-actions bot locked and limited conversation to collaborators Sep 26, 2025
@metamaskbot metamaskbot added the release-13.5.0 Issue or pull request that will be included in release 13.5.0 label Sep 26, 2025
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
release-13.5.0 Issue or pull request that will be included in release 13.5.0 size-M team-swaps-and-bridge Swaps and Bridge team
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants