fix(wallet): fix into_descriptor_key for DescriptorPublicKey#1902
Closed
ValuedMammal wants to merge 1 commit intobitcoindevkit:masterfrom
Closed
fix(wallet): fix into_descriptor_key for DescriptorPublicKey#1902ValuedMammal wants to merge 1 commit intobitcoindevkit:masterfrom
into_descriptor_key for DescriptorPublicKey#1902ValuedMammal wants to merge 1 commit intobitcoindevkit:masterfrom
Conversation
..by including the missing match arm for `DescriptorPublicKey::MultiXPub` when initializing `networks`. Test that `into_wallet_descriptor` correctly parses a multipath descriptor and fails if passed a network that is invalid for the descriptor. Note that rust-miniscript doesn't support parsing a multipath descriptor containing extended private keys.
aagbotemi
reviewed
Mar 20, 2025
Contributor
aagbotemi
left a comment
There was a problem hiding this comment.
Including the match arm for multipath fixes the issue. Welldone @ValuedMammal
5 tasks
Collaborator
oleonardolima
left a comment
There was a problem hiding this comment.
cACK 8eaf35c
However, I think we should move with #1906 altogether, otherwise it would only partially solve the problem, at least while testing as this PR doesn't add support for multipath descriptor it'll still fail when trying to insert a descriptor, as it interprets as a single descriptor wallet and we're unable to calculate the descriptor_id as it's.
8 tasks
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.
Fix
into_descriptor_keyforDescriptorPublicKeyby including the missing match arm forDescriptorPublicKey::MultiXPubwhen initializingnetworks.Test that
into_wallet_descriptorcorrectly parses a multipath descriptor and fails if passed a network that is invalid for the descriptor.Note that rust-miniscript doesn't support parsing a multipath descriptor containing extended private keys.
fixes bitcoindevkit/bdk_wallet#10
Changelog notice
Fixed an issue preventing
into_wallet_descriptorfrom correctly mapping a DescriptorPublicKey to the set of available networks.Checklists
All Submissions:
cargo fmtandcargo clippybefore committingBugfixes: