chore: integrate MultichainAccountService changes#38265
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. |
Builds ready [511315f]
📊 Page Load Benchmark ResultsCurrent Commit: 📄 Localhost MetaMask Test DappSamples: 100 Summary
📈 Detailed Results
Bundle size diffs [🚨 Warning! Bundle size has increased!]
|
|
All alerts resolved. Learn more about Socket for GitHub. This PR previously contained dependency changes with security issues that have been resolved, removed, or ignored. |
Builds ready [a15aaad]
📊 Page Load Benchmark ResultsCurrent Commit: 📄 Localhost MetaMask Test DappSamples: 100 Summary
📈 Detailed Results
Bundle size diffs [🚨 Warning! Bundle size has increased!]
|
|
@metamaskbot update-policies |
|
Policy update failed. You can review the logs or retry the policy update here |
|
@metamaskbot update-policies |
|
Policy update failed. You can review the logs or retry the policy update here |
|
@metamaskbot update-policies |
|
No policy changes |
Builds ready [55412fc]
UI Startup Metrics (1366 ± 91 ms)
📊 Page Load Benchmark ResultsCurrent Commit: 📄 Localhost MetaMask Test DappSamples: 100 Summary
📈 Detailed Results
Bundle size diffs [🚨 Warning! Bundle size has increased!]
|
| * @returns {Promise<string>} The address of the newly created account | ||
| * @throws Will throw an error if keyring creation fails | ||
| */ | ||
| async generateNewMnemonicAndAddToVault() { |
There was a problem hiding this comment.
Removing this entirely since there's no equivalent in our service. Also, this is dead code right now, this got added during the multi-SRP initiative but has never been used (apart from unit tests)
|
@metamaskbot update-policies |
|
Policies updated. 🧠 Learn how: https://lavamoat.github.io/guides/policy-diff/#what-to-look-for-when-reviewing-a-policy-diff 👀 lavamoat/browserify/beta/policy.json changes differ from main/policy.json policy changes |
Builds ready [6fb1713]
UI Startup Metrics (1414 ± 108 ms)
📊 Page Load Benchmark ResultsCurrent Commit: 📄 Localhost MetaMask Test DappSamples: 100 Summary
📈 Detailed Results
Bundle size diffs [🚨 Warning! Bundle size has increased!]
|
Builds ready [4697677]
UI Startup Metrics (1352 ± 98 ms)
📊 Page Load Benchmark ResultsCurrent Commit: 📄 Localhost MetaMask Test DappSamples: 100 Summary
📈 Detailed Results
Bundle size diffs [🚨 Warning! Bundle size has increased!]
|
Builds ready [456f170]
UI Startup Metrics (1342 ± 85 ms)
📊 Page Load Benchmark ResultsCurrent Commit: 📄 Localhost MetaMask Test DappSamples: 100 Summary
📈 Detailed Results
Bundle size diffs [🚨 Warning! Bundle size has increased!]
|
Description
This PR aims to delegate account (wallet) creation logic to the
MultichainAccountService. The intention is to make it easier to build with the new mental model for accounts. The latest version of the service also incorporates a large refactor that aims to improve the performance of the service.Changelog
CHANGELOG entry: Refactor account creation logic to use the
MultichainAccountServicefor creating walletsRelated issues
Fixes: N/A
Manual testing steps
Screenshots/Recordings
N/A
Pre-merge author checklist
Pre-merge reviewer checklist
Note
Medium Risk
Touches core onboarding/vault creation and SRP import/restore paths, so regressions could block wallet setup or account discovery across chains despite test updates.
Overview
Routes wallet/vault creation flows (
createNewVaultAndKeychain, SRP import, andcreateNewVaultAndRestore) throughmultichainAccountService.createMultichainAccountWalletand uses the returnedentropySourcefor subsequent account discovery/selection; onboarding now safely handles missing selected account and passes the selected account’s entropy id intodiscoverAndCreateAccounts.Removes the legacy
generateNewMnemonicAndAddToVaultbackground method and its UI thunk/tests, updates multichain discovery and sorting to use direct service/controller APIs (multichainAccountService.getMultichainAccountWallet,accountTreeController.getAccountContext), and adjusts unit/e2e tests plus LavaMoat policies and core package versions (account-tree-controller,accounts-controller,keyring-controller,multichain-account-service).Written by Cursor Bugbot for commit 456f170. This will update automatically on new commits. Configure here.