Repository navigation
Error parsing combo descriptor #31
Description
Activity
Yes the miniscript library does not support all descriptor types mentioned in BIPs.
combois one of them as far as I understand. They don't have a lot of docs on why certain descriptors are supported, but you can see this comment mentioning they don't plan on adding support.Is there something you're trying to do we can maybe implement in a different way? Let me know your use case.
Reacted by surfer190Had a bitcoin-core legacy wallet with utxo in derivation paths
m\0'\0'\0'tom\0'\0'\2'which are non-standard according to BIP32.
Migrated to a bitcoin core descriptor wallet.
Wanting to import the wallet addresses into gui based wallets like sparrow and bitcoin safe - as a watch only online wallet - so that creating unsigned transactions are easier and less error prone.Bitcoin core created descriptor like this
combo(tpubD6NzVbkrYhZ4YSPGUiT67AZRVmJUjPn1Twt4JuYPrkGZiwVKyBofjVRej8A194X2X4Toyo22HSaJJYLH2g4gd2JGnztsKzShiRFwWgAYi5D/0h/0h/*h)#leqp7cnzseemingly for them\0'\0'\0'tom\0'\0'\2'paths.Tried to import it with sparrow and it complained about bad derivation paths.
bitcoin safe developer said changing the descriptor from
combotopwkhcould work, tried it and an error arose and apparently that is the bdk integration.Example with
pwkh:from bdkpython.bdk import Descriptor, Network TEST_NETWORK = Network(1) DESC = "pwkh(tpubD6NzVbkrYhZ4YSPGUiT67AZRVmJUjPn1Twt4JuYPrkGZiwVKyBofjVRej8A194X2X4Toyo22HSaJJYLH2g4gd2JGnztsKzShiRFwWgAYi5D/0h/0h/*h)" my_desc = Descriptor(descriptor=DESC, network=TEST_NETWORK)Error / Traceback:
Traceback (most recent call last): File "/Users/s/projects/bdk_playground/check.py", line 11, in <module> my_desc = Descriptor(descriptor=DESC, network=TEST_NETWORK) File "/Users/s/projects/bdk_playground/env/lib/python3.10/site-packages/bdkpython/bdk.py", line 17768, in __init__ self._pointer = _uniffi_rust_call_with_error(_UniffiConverterTypeDescriptorError,_UniffiLib.uniffi_bdkffi_fn_constructor_descriptor_new, File "/Users/s/projects/bdk_playground/env/lib/python3.10/site-packages/bdkpython/bdk.py", line 295, in _uniffi_rust_call_with_error _uniffi_check_call_status(error_ffi_converter, call_status) File "/Users/s/projects/bdk_playground/env/lib/python3.10/site-packages/bdkpython/bdk.py", line 306, in _uniffi_check_call_status raise error_ffi_converter.lift(call_status.error_buf) bdkpython.bdk.DescriptorError.Miniscript: error_message='unexpected «pwkh(1 args) while parsing Miniscript»'Checking on bitcoin core...deriveaddresses with the public descriptor of
combo(....)returnedCannot derive script without private keys
Tested with bitcoin safe and the private descriptor did import ascombo(...). Seems it is necessary for hardened derivation paths.
When initialising a
combodescriptor this error was raised:Is this a legitimate error with the descriptor?
Code
Traceback