I have a question about how the bitcoin core wallet works with descriptors.
I am creating a wallet using the
createwallet method and passing in a name (all other args are default).
I then import addresses into Bitcoin Core using
wsh(sortedmulti(2,[abc123ef/48h/0h/0h/2h]xpubyadayada.../0/*, [abc345ef/48h/0h/0h/2h]xpubyadaya1da.../0/*, [abc567ef/48h/0h/0h/2h]xpubyadaya2da.../0/*))#checksum
When I run
wsh(sortedmulti(2,[abc123ef/48h/0h/0h/2h]xpubyadayada.../0/*, [abc345ef/48h/0h/0h/2h]xpubyadaya1da.../0/*, [abc567ef/48h/0h/0h/2h]xpubyadaya2da.../0/*))#checksum I get the expected addresses as an output but when I run the
getnewaddress command after running
importmulti, I get an address but not any of the addresses that were output from
I then noticed there is a
disable_private_keys option when creating the wallet, so I've setup a new wallet using that flag.
I go through the setup process again with
keypool=true when importing multi but when I run
getnewaddress I get
"Error: This wallet has no available keys". The importmulti call returns
success: true, and I get
Already have script 522103b403e66... in my logs when I try running the command twice.
getnewaddress not work with descriptors? Or am I setting up the wallet incorrectly? I see there is an argument
blank to pass in when creating a wallet but when I try that and import I get
Error: This wallet has no available keys too.
I would expect
getnewaddress to output the first address returned from
deriveaddresses on a fresh wallet. Have I overlooked something in the documentation?
I looked at these docs too and I think I've followed them exactly: https://gist.github.com/achow101/a9cf757d45df56753fae9d65db4d6e1d