Closed mbican closed 6 months ago
Thanks for the report! I'm going to label this as a feature request rather than a bug as this is expected behavior given the feature support currently in Caravan. Basically, Caravan supports reading from the different xpub types to make it possible to import xpubs from trezor and electrum primarily, but then stays fully in the world of xpubs. Unfortunately, BIP84/SLIP0132 are not fully supported standards yet across all wallets and so Caravan for now has opted to keep extended public keys with the xpub/tpub prefixes while making sure to explicitly store the HD path in its config. Electrum won't know how to read this xpub, but you should be able to find tools that can convert the xpub from Caravan given the HD path into the zpub that Electrum understands.
If you're interested in helping adding support for this, the first place I'd recommend looking is in the unchained-bitcoin
library, specifically the tools used for converting xpub prefix versions here
Thanks
Thanks for the report! I'm going to label this as a feature request rather than a bug as this is expected behavior given the feature support currently in Caravan. Basically, Caravan supports reading from the different xpub types to make it possible to import xpubs from trezor and electrum primarily, but then stays fully in the world of xpubs. Unfortunately, BIP84/SLIP0132 are not fully supported standards yet across all wallets and so Caravan for now has opted to keep extended public keys with the xpub/tpub prefixes while making sure to explicitly store the HD path in its config. Electrum won't know how to read this xpub, but you should be able to find tools that can convert the xpub from Caravan given the HD path into the zpub that Electrum understands.
If you're interested in helping adding support for this, the first place I'd recommend looking is in the
unchained-bitcoin
library, specifically the tools used for converting xpub prefix versions here
Thanks @bucko13 for the information
You could use this tool https://jlopp.github.io/xpub-converter/ to convert the xpub
back to Zpub
for usage in other wallets.
The Caravan Library is transitioning to a new home, and as part of this move current issues will be closed and archived. Please go check out the new location here: https://github.com/caravan-bitcoin/caravan/issues
if I import Zpub it is immediately converted to xpub e.g.: Zpub6xvDzwpKHczhpJzkkveFAqAsayzq7dC49Rr3R1qP8cGivqrMbUEip1fRbThiDLhtWA9EptBSVvUrKdrwwp7jt4bePNL3b7d9bo9EvgBQB4T -> xpub68McGNk3RJMNh9T99Yc1vae4XFfg22XTzw9vvxn4zpgZCTezKkXKUmVDkLq4f6B9TQqeTLzChPPFRu24DC8m977mpDpo1tXBAck5Za3Vosz
If I later take the xpub from json and put it to electrum it doesn't work :-(
I'm submitting a Bug report
Expected Behavior
as per slip-0132 https://github.com/satoshilabs/slips/blob/master/slip-0132.md based on script type extended public key should start with P2SH: xpub Multi-signature P2WSH in P2SH: Ypub Multi-signature P2WSH: Zpub
I would want to convert to appropriate type *pub based address type
Current Behavior
Currently regardless of address type extended public key is always converted to xpub. It shows incorrect error message: "Your extended public key has been converted from Zpub to xpub, this may indicate an invalid network setting, if so correct setting, remove key and try again"
Possible Solution
Steps to Reproduce (for bugs)
Environment
Browser and version: Brave Version 1.9.72 Chromium: 81.0.4044.138 (Official Build) (64-bit)