feat: add wallet creation and restoration methods to UniFFI bridge#52
Merged
xdustinface merged 1 commit intov0.42-devfrom Mar 14, 2026
Merged
feat: add wallet creation and restoration methods to UniFFI bridge#52xdustinface merged 1 commit intov0.42-devfrom
xdustinface merged 1 commit intov0.42-devfrom
Conversation
|
This PR has merge conflicts with the base branch. Please rebase or merge the base branch into your branch to resolve them. |
9a359e0 to
c6952bf
Compare
c6952bf to
6b37b76
Compare
|
This PR has merge conflicts with the base branch. Please rebase or merge the base branch into your branch to resolve them. |
6b37b76 to
66c1d65
Compare
66c1d65 to
d807768
Compare
- Add WalletCreationResult record type with mnemonic and wallet_id fields - Add Wallet error variant to SpvClientError - Add SpvClient::create_wallet(word_count) method for generating new wallets with BIP39 mnemonic - Add SpvClient::restore_wallet(mnemonic) method for restoring wallets from mnemonic phrase - Add standalone validate_mnemonic(mnemonic) function for mnemonic validation - Add comprehensive unit tests for all new functionality Closes #50 Co-authored-by: Kevin Rombach <xdustinface@users.noreply.github.com>
|
Codecov Report❌ Patch coverage is
Additional details and impacted files@@ Coverage Diff @@
## v0.42-dev #52 +/- ##
=============================================
- Coverage 73.08% 67.79% -5.30%
=============================================
Files 287 316 +29
Lines 58264 68644 +10380
=============================================
+ Hits 42584 46538 +3954
- Misses 15680 22106 +6426
🚀 New features to boost your workflow:
|
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.
Closes #50
Adds wallet creation and restoration methods for the React Native onboarding flow:
WalletCreationResultUniFFI record withmnemonicandwallet_idSpvClientError::Walleterror variantcreate_wallet(word_count: u8)— generates BIP39 mnemonic (12 or 24 words) and creates walletrestore_wallet(mnemonic: String)— restores wallet from existing mnemonicvalidate_mnemonic(mnemonic: String) -> bool— standalone UX validation