perf(multichain-account-service): add v2 createAccounts (account batching when supported)#8131
Open
perf(multichain-account-service): add v2 createAccounts (account batching when supported)#8131
createAccounts (account batching when supported)#8131Conversation
8f805c8 to
6d1259e
Compare
716a57a to
16a70a6
Compare
6d1259e to
99d0aa2
Compare
packages/multichain-account-service/src/providers/SolAccountProvider.ts
Outdated
Show resolved
Hide resolved
18c070d to
05ecd6a
Compare
25d09e4 to
957ea19
Compare
6fd4e76 to
fb482ca
Compare
packages/multichain-account-service/src/providers/SolAccountProvider.ts
Outdated
Show resolved
Hide resolved
packages/multichain-account-service/src/providers/SnapAccountProvider.ts
Outdated
Show resolved
Hide resolved
fb482ca to
20605ec
Compare
957ea19 to
222e1eb
Compare
20605ec to
4feb6e9
Compare
packages/multichain-account-service/src/providers/SolAccountProvider.ts
Outdated
Show resolved
Hide resolved
packages/multichain-account-service/src/providers/TrxAccountProvider.ts
Outdated
Show resolved
Hide resolved
…apAccountProvider
createAccounts (account batching when supported)
There was a problem hiding this comment.
Cursor Bugbot has reviewed your changes and found 1 potential issue.
Bugbot Autofix is OFF. To automatically fix reported issues with cloud agents, have a team admin enable autofix in the Cursor dashboard.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.

Explanation
Implementing proper batching for our Solana account provider.
References
:createMultichainAccountGroupsaction to batch account creation #7801Checklist
Note
Medium Risk
Changes core Snap-based account creation to optionally use
SnapKeyring.createAccountsfor single and range derivations; misconfiguration or Snap incompatibilities could impact account creation or indexing across Sol/BTC/TRX.Overview
Adds a config-gated v2 path for Snap-based providers to batch BIP-44 account creation via
SnapKeyring.createAccounts, while keeping the existing per-account v1 flow as the default.Refactors
SnapAccountProviderto owncreateAccountsvalidation + timeout handling and introduces provider overrides (createAccountV1, optionaltoBip44Account) soSolAccountProvider,BtcAccountProvider, andTrxAccountProviderreuse shared batching logic; discovery now creates accounts through the shared helper.Updates defaults to include
createAccounts.v2: false, expands unit tests to cover v1 vs v2 behavior (single, range, idempotency, timeout), and adds small test utilities (DeepPartial,toGroupIndexRangeArray).Written by Cursor Bugbot for commit 130af27. This will update automatically on new commits. Configure here.