chore: Update accounts controller to v23 and related packages (transaction controller etc)#13436
chore: Update accounts controller to v23 and related packages (transaction controller etc)#13436owencraston merged 20 commits intomainfrom
Conversation
|
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. |
f787633 to
e1a6c36
Compare
48a5ca2 to
4292b49
Compare
|
2667656 to
b04ed3b
Compare
|
|
Codecov ReportAll modified and coverable lines are covered by tests ✅
Additional details and impacted files@@ Coverage Diff @@
## main #13436 +/- ##
=======================================
Coverage 61.83% 61.83%
=======================================
Files 1975 1977 +2
Lines 43847 43854 +7
Branches 5926 5928 +2
=======================================
+ Hits 27111 27118 +7
Misses 14935 14935
Partials 1801 1801 ☔ View full report in Codecov by Sentry. |
|
2502053
0e35bd9 to
2502053
Compare
|
|
I've noticed e2e failures on main since yesterday. |
|



Description
This PR updates the AccountsController and the TransactionController. These are the two major updates however there are a few smaller peer dep updates as well. Here is a description of the changes...
"@metamask/accounts-controller": "^21.0.0" -> 23.1.0"
@metamask/snaps-{sdk,utils,controllers}core#5265)@metamask/{keyring-api,eth-snap-keyring}core#5280)@metamask/{keyring-api,eth-snap-keyring}core#5280)@metamask/snaps-{sdk,utils,controllers}core#5265)@metamask/snaps-{sdk,utils,controllers}core#5265)"@metamask/transaction-controller": "^43.0.0" -> 45.1.0
"@metamask/keyring-api": "^13.0.0" -> 17.0.0
definePatternaccounts#150) It used to be a string but it has been restricted with a template literal type that matches CAIP-19 asset type.scopesmore restrictive accounts#159)scopescontains CAIP-2 chain IDs accounts#165) Initially scopes accepted CAIP-2 namespaces as well to address the EVM EOA accounts that supports all EVM chains. This has been dropped in favor of eip155:0 scope.scopescontains CAIP-2 chain IDs accounts#165)"@metamask/keyring-internal-api": "^2.0.0" -> 4.0.2
The scopes from each AccountStruct types is now more strict (remove support of CAIP-2 namespaces) which impact all InternalAccountStruct types.
"@metamask/eth-snap-keyring": "^7.1.0" -> 10.0.0
scopesfield toKeyringAccountaccounts#101)This change was not properly reported as breaking on the 7.1.0.
KeyringAccount and InternalAccount have a new required field (scopes) and are part of the public API.
This change was not properly reported as breaking on the 7.1.0.
InternalAccount extends KeyringAccount which has a new required field (scopes) and is part of the public API.
This change was not properly reported as breaking on the 7.1.0.
KeyringAccount has a new required field (scopes) and is part of the public API.
Messengerinstead ofSnapsControlleraccounts#152)This allows to break the runtime dependency we had with some snaps-* pacakges.
scopesmore restrictive accounts#159)We now use specific *AccountStucts when checking created/updated accounts to make the scopes sent by the Snap are valid regarding their account type definition.
This was missing from SIP-26, but we expect this address to be CAIP-10 compliant.
"@metamask/snaps-sdk": "^6.13.0" -> 6.17.1
"@metamask/snaps-utils": "^8.6.1" -> ^8.10.0
Related issues
Fixes: #13374
Fixes: #13377
Manual testing steps
Testing snap accounts
METAMASK_BUILD_TYPEtoflaskin your.js.envTesting transactions
METAMASK_BUILD_TYPEtomainin your.js.envScreenshots/Recordings
Before
After
On-boarding and Account Creation Flow
Screen.Recording.2025-02-12.at.9.11.39.PM.mov
Send flow
Screen.Recording.2025-02-12.at.9.30.18.PM.mov
Pre-merge author checklist
Pre-merge reviewer checklist