RGB-WG / rgb

RGB smart contracts: command-line tool & wallet runtime library for desktop and mobile integration
https://rgb.tech
Apache License 2.0
129 stars 34 forks source link

bug:can`t import wallet by using descriptor #75

Closed EthanShang8989 closed 8 months ago

EthanShang8989 commented 8 months ago

I can't import one wallet. But my other wallet can. rgb github commit hash is 680102aa97426760c02a94e9e192b7cc69017b7b I had two wallets when I was testing. One of my wallets works. But one of them doesn't work. I tested both win and linux environments with the same problem

PS D:\rgb> rgb create -d .alice default --tapret-key-only "[6786b8cc/86h/1h/0h]tpubDCSs4JU4Kpae7ibt45FEPZb4FGcfvPhsmKCkdk6NDwSGQk2QSBS5t1txw6QoCFnDPiRtS8Tq1orGBVoeXKexNQSPor1FmLnKPCSKhqkjBSF/<0;1>/*"
RGB: command-line wallet for RGB smart contracts
     by LNP/BP Standards Association

Unable to find or parse config file; using config defaults
Loading descriptor from command-line argument ... success
Syncing ......................................................thread 'main' panicked at 'source slice length (21) does not match destination slice length (20)', C:\Users\13599\.cargo\registry\src\mirrors.ustc.edu.cn-61ef6e0cd06fb9b8\bp-invoice-0.11.0-beta.3\src\address.rs:321:19
note: run with `RUST_BACKTRACE=1` environment variable to display a backtrace

I am using the sparrow wallet.mnemonic word: cannon loud robust fee layer flame slot either unlock upset net immense gasp erosion three able cook liar insect tool method extend fetch worry

image

dr-orlovsky commented 8 months ago

You need <0;1;9;10> at the end of descriptor to make it RGB-compatible.

Also make sure to use the tip of v0.11 branch - the master contains multiple known errors

EthanShang8989 commented 8 months ago

Still not working. I have already updated to commit hash 9d9193573a79bfb4db1c0e31cb94cbc68f0a4b75, but the issue remains the same. Have you tried using my mnemonic phrase? By the way, I encountered a problem while using the 'prepare' command.

rgb -d .bob prepare  rgb:mnCzb34-uMBtp6Wkg-osacgQtvk-gc8zksi9M-ai7bwmCdr-obz2KC/RGB21/1+tb1pe2uwf8vcfxn29lzwzjnamq2aqz9huarh5923cawu8ymypxvjvjgsma9ffa 200 testPsbtFile

Loading descriptor from wallet default ... success
Loading stock ... success
Error: impossible to construct transaction having no inputs.

I have already sent some test coins to the addresses generated by the 'address' command with the path '/9/*' for Alice and Bob. I'm not quite sure how to proceed. Additionally, when using the 'state' command, I can't see the 'assestOwner' of the Rgb21 contract."。

dr-orlovsky commented 8 months ago

It seems you are using v0.10 not v0.11

EthanShang8989 commented 8 months ago

I'm not using v0.10.

 rgb -V
rgb-wallet 0.11.0-beta.2

Maybe it's reason , I deleted the : ”command-line wallet for RGB smart contracts by LNP/BP Standards Association“,which makes you think I'm v0.10.

dr-orlovsky commented 8 months ago

It works with v0.11.0-beta.3 which I have released today. Please feel free to re-open if you will still have a problems