Grinnode-live / 2020-grin-bug-bash-challenge

Finding bugs in Grin-Wallet & Grin-nodes for a bounty prior to Grin fork v5.
3 stars 1 forks source link

[GRIN-Wallet] Test Slatepack flow (Text) #17

Closed phyro closed 3 years ago

phyro commented 3 years ago

Description: Test that transacting with Slatepacks works by outputting text.

Slatepack text transacting should work for both flows:

  1. sender-initiated send -> receive -> finalize and
  2. receiver-initiated (invoice) flow invoice -> pay -> finalize

Prerequisites: Setup two GRIN-Wallets (1) + (2) and send funds from wallet (1) to wallet (2) via Slatepacks through Text method.

Example: grin-wallet send --manual -d ....

You will create a transaction and check the behavior of wallet (1) and wallet (2) if there is any problems.

Expected result: You should be able to finalize the transaction later on wallet (1) whenever you want, without any problems.

Note: More about these flows can be read on:

  1. https://docs.grin.mw/getting-started/quickstart/send/
  2. https://docs.grin.mw/about-grin/transactions/
  3. https://docs.grin.mw/getting-started/wallet-handbook/#invoice
  4. https://docs.grin.mw/getting-started/wallet-handbook/
mojitoo commented 3 years ago

Prerequisites:

Step 1 (Wallet 1 : sender side)

The send command is the first step of building an interactive transaction. Both wallets will interact in an asynchronous process by exchanging copy-pastable strings called slatepacks.

By using --manual flag, the user is deliberately choosing to not attempt to interact via Tor and only output slatepack message. The output slatepack is also encypted for the recipient only, since the sender provided an address (which is a public key) by using the -d flag. Last but not least, the send need to specify the amount to send.

grin-wallet send --manual -d grin1jdj2w0fh8haq9pfuvjmjrev5f4gs34n4n7fnsfmuwf7j09x4v9ws79nq8d 0.1

Following this command the user needs to enter his password wallet to get the slatepack message displayed on screen and also an output to a .slatepack file. he either have the choice to copy the slatepack message and send it to the receiver or provide him with the slatepack file.

Password: 

/Users/workstation/.grin/main/slatepack/3b9e526a-9f30-4ea2-86ae-4220e4f52c95.S1.slatepack

Slatepack data follows. Please provide this output to the other party

--- CUT BELOW THIS LINE ---

BEGINSLATEPACK. D5SgZ6kZbDPqVcH uu9kRyRs26Lz2nD GSSVgfdByAGdLtr gWZ3ioobHw6Gzzx xy4tnsRLBeXMkvb X8XsiiyutHxDGeR
NC3BwuEGsQFbuv4 wNQxHXMi9BcYmVA XVvNumgjbtp8K2r fbeow3HvJ1CwLWg LT1nxhb4Wi1PX23 p5XvAUG8xh9JdhG H2VStmNAw7KRkWh
VdyaF6ni74WMqyk f1cnqQTdUpC4YEj ve5okzogxG7DirU Fs7sKbL2DD43NEe P4kN7yBZFbd5uve GNsEU7XYJkcAxHU PCqRHQAXbtBvRtp
DVMFFy5qsMnnRGu TAPnRFZkSWorRGy VqmYugQN7Zm7mvH fK2GUHGwh5LwDfs g8neHCachokRVq5 7JDhHnkU29mJ7x3 K2sq1Dpv2qap37Y
jyciAgAPBwrFhiM JmqrVVyvhhvr133 fFRjgPKoJyS1sBi 2SwtcMBZxSDLfLm oWUaCEb1op5n8sW rEc95LVcfJhkbKV DgBFGAFboeDvkuo
o7QHZwrXtrawhJK BkZSVadis3rTUi7 6F55oab6Au8E1Qw F1ebiF5UnCzjfbb ZEgDwMmBVqFTje3 Fg1ydr8Yy9LQxfo sWp75QhdYHhMPmu
aeHpJEJBDGWXUM3 tkZ8Mk2Lyg97Vys SUHSUrW5WENrh8d Ygh5gggLp31r1vd 74AkcGW8NLqNvRo 7DpVSF2Rr7DUgbY Cf6mvUSjzyJsiYG
WyUN1nUYA9C8yMk XSC67u72Zdt6bzc bCunjs1HFoFvkgJ KubUMHvfSSM7cGs 89quCoH8Wv4mSzy CJU3rDuCR5zAjQv U3LqNyNENGXyB94
jYeBtQQt12Riyzy Xc9vaDrMW28HEkd smQRMQBoxnVHVqU pDT3CdXXahYWpeT hz93aHQA8GodYpC 3X98bWSEJRHqar. ENDSLATEPACK.

--- CUT ABOVE THIS LINE ---

Slatepack data was also output to

/Users/workstation/.grin/main/slatepack/3b9e526a-9f30-4ea2-86ae-4220e4f52c95.S1.slatepack
The slatepack data is encrypted for the recipient only

Command 'send' completed successfully 

Step 2 (Wallet 2 : receiver side):

The receiver needs to process the slatepack message using the receive command beside the --manual flag to not attempt to interact via Tor and only output slatepack message. After entering the command, the receiver will be prompted to input the received slatepack. Right after the wallet will output another slatepack message to provide the sender, so he can finalize the transaction.

grin-wallet receive --manual
Please paste your encoded slatepack message:

BEGINSLATEPACK. D5SgZ6kZbDPqVcH uu9kRyRs26Lz2nD GSSVgfdByAGdLtr gWZ3ioobHw6Gzzx xy4tnsRLBeXMkvb X8XsiiyutHxDGeR
NC3BwuEGsQFbuv4 wNQxHXMi9BcYmVA XVvNumgjbtp8K2r fbeow3HvJ1CwLWg LT1nxhb4Wi1PX23 p5XvAUG8xh9JdhG H2VStmNAw7KRkWh
VdyaF6ni74WMqyk f1cnqQTdUpC4YEj ve5okzogxG7DirU Fs7sKbL2DD43NEe P4kN7yBZFbd5uve GNsEU7XYJkcAxHU PCqRHQAXbtBvRtp
DVMFFy5qsMnnRGu TAPnRFZkSWorRGy VqmYugQN7Zm7mvH fK2GUHGwh5LwDfs g8neHCachokRVq5 7JDhHnkU29mJ7x3 K2sq1Dpv2qap37Y
jyciAgAPBwrFhiM JmqrVVyvhhvr133 fFRjgPKoJyS1sBi 2SwtcMBZxSDLfLm oWUaCEb1op5n8sW rEc95LVcfJhkbKV DgBFGAFboeDvkuo
o7QHZwrXtrawhJK BkZSVadis3rTUi7 6F55oab6Au8E1Qw F1ebiF5UnCzjfbb ZEgDwMmBVqFTje3 Fg1ydr8Yy9LQxfo sWp75QhdYHhMPmu
aeHpJEJBDGWXUM3 tkZ8Mk2Lyg97Vys SUHSUrW5WENrh8d Ygh5gggLp31r1vd 74AkcGW8NLqNvRo 7DpVSF2Rr7DUgbY Cf6mvUSjzyJsiYG
WyUN1nUYA9C8yMk XSC67u72Zdt6bzc bCunjs1HFoFvkgJ KubUMHvfSSM7cGs 89quCoH8Wv4mSzy CJU3rDuCR5zAjQv U3LqNyNENGXyB94
jYeBtQQt12Riyzy Xc9vaDrMW28HEkd smQRMQBoxnVHVqU pDT3CdXXahYWpeT hz93aHQA8GodYpC 3X98bWSEJRHqar. ENDSLATEPACK.

/Users/workstation/.grin/main/slatepack/3b9e526a-9f30-4ea2-86ae-4220e4f52c95.S2.slatepack

Slatepack data follows. Please provide this output to the other party

--- CUT BELOW THIS LINE ---

BEGINSLATEPACK. e5FtW83RA9nXEvA Urnp4szLip9unnv SroH4k77oU9xAg9 cJbyg6mwCU9Eqcv mWGLMasD5gZFhJX eBYS2Zu8pRazYFC
X3YfYD4FufESFXG BSmPkbaBMGtFeFL otoYbtFUgFjhfiN EU7qEPjKHWnfLzq RzZHR6tUCVn9awC p3RWvTZdCL6gmHx uWJT6i7zgWDzHGa
uE6XVW7VJiUCvsb fgJs1URUXvNv5e7 uSJAS8ALRGwhppo smDeQdZoSpkybZt RxVyet9D632zrPN q3KbjgBRWn6XvpA XBV1inhgu4kciA9
enQaj5UMcAdpCG9 xzhNe7Cqw8eaVkE CZeNq3xrx3nMsLN KmHGNWuEp5mY9j9 d8BzA27GrajUw4c Tt8Qm8x7kRk2y3Z TquJzdx2Z7A4UbA
vjBP1ecaHgMLuZh jbZaJY1BquG1g8U LhG67u1A6MftHpA meNoG6LcLJasnVy wCY2C3gjN85RxFK aCyG4z4oWmsvZAd foAzVTVKGe1KwBs
qP2kZJUchY1Rx2o pSxUjKphrFtERgb mKUCNdzXmLt7dZK QyRZB2ymdsqdwN1 kwpVPxHCsgyReyU dLGKs5rUsRTypeJ 5m1Ni8LYXoDk9fT
97dMM4dpaanv6Ey zo9TFXK95s1Rh5x j6spbLdBN1DWwKz q3hSGxDgNTPsTVW WZuhGaFxbvWBin3 UU2CJsTWMQV33RH e7JC5ePbzrbipEF
i22aY6R2rfV7bcA Riz5HNDNTcbGcab c3sbA1zaZ4WVC4u eiTn7qBN7zxtTmD EGfseyKnHtAM8Gj jNbPWXjA43WHmAq BR8tk7TuvQ4UdHt
gDdPKxu3B8oLPsu qLkKZXCx8tttSBc RXuxUrSCmcmXZ9e G1464DNejddSQtK rQNpgkinNGVFnVH KvgSdFoLDMX9V8E k6oGncMGyQshoo7
uEjWQMVm57jmptH WQ9gbdanmYqEZ2n gkMDLsV86tMiboT dDfj1o9wzde59im ScpFgb6CHpKdE8C CjVdcKnY79n4RkF JQ5rCcerCzRqygd
YQaexJDvUbrg9XN GiroH7nVYtawjr5 FBU8hfXUesG6rDt 8pjukXNRVkqNg2Y fzez1W9crReJkym 3ehjU7nnD5sHFko 3WFYzBijf94tdJV
dwCRXKjKypfDfwF F32g6HCkRQFBwCk KTvu7LZaBjv2M2a 3aHDXbdtACX8r6i 1wJTvoTdBkADwb2 CGrJ2PqzwKWR7g8 FPzBaL8qh95Y55L
mHxXqc1PzQUbt28 qcR35PuQ4uAQzu7 oBMtgG7UhkhTjSz DAdRF6np9QGiSjT EmVpGWAmxmwg3e3 vRUjHpYYLk3uGo1 tJ4FWLWTpb5fw7D
Q94qen9sLBrfzj3 PJ5GZvdLGUaNjVm kiCBn3mLCvdyeVv YZoSRZTVBVHtmJ9 rgyi9YqdruGCz1W VG3NrbB8sEb8VqH Q9xe6uHA4EwqnJY
AUY3w53DvPBMiFH QvySC2ifvkoAKuj iVNh3Amm6so7Aea QfxSxFaKPJmXBxW hmw2krPJERzb87S GJqC7af1uT8SWgD eAJUCoXQgqnZbCJ
wyZqoLKfWjv1c7M yVojkE5LzoeC2zg aBzRPC8Dx9a4Zem oowidC7E5vHWdMV 52N9iwrha2REymF fe5Xbask7Rm1iK9 34y4wD79rqhZA6P
ovdQcYvGycfM4A9 7AoU3viC1t1uANg YAkdW393UuEUCJg wzRE9U8DXuJsoFo ye5PZguUuA6inUX CfktFM7sfbSCjiw FVX41GypC9esDTX
9PBtPVL6QdhXsEW LrSGoFz8dSPMWhK 9mZoyYd9ahCdiTH tGcX1Jz2NWBCHSw viej3HZDxnQ2uAH 1W5FZVGycZ4dFms 3ZN2rzdHX5UWCmr
iyBuo3XokHehefW CcWSkLbXvaUdnNd BfreyHTeeRWk7QR mMJFRs3. ENDSLATEPACK.

--- CUT ABOVE THIS LINE ---

Slatepack data was also output to

/Users/workstation/.grin/main/slatepack/3b9e526a-9f30-4ea2-86ae-4220e4f52c95.S2.slatepack

The slatepack data is encrypted for the recipient only

Command 'receive' completed successfully

Step 3 (Wallet 1 : sender side) :

The finalize command is the final step to any slatepack transaction. After entering the command, the sender will be prompted to input the slatepack message provided by the receiver to finalize the transaction

grin-wallet  finalize
Please paste your encoded slatepack message:
BEGINSLATEPACK. e5FtW83RA9nXEvA Urnp4szLip9unnv SroH4k77oU9xAg9 cJbyg6mwCU9Eqcv mWGLMasD5gZFhJX eBYS2Zu8pRazYFC
X3YfYD4FufESFXG BSmPkbaBMGtFeFL otoYbtFUgFjhfiN EU7qEPjKHWnfLzq RzZHR6tUCVn9awC p3RWvTZdCL6gmHx uWJT6i7zgWDzHGa
uE6XVW7VJiUCvsb fgJs1URUXvNv5e7 uSJAS8ALRGwhppo smDeQdZoSpkybZt RxVyet9D632zrPN q3KbjgBRWn6XvpA XBV1inhgu4kciA9
enQaj5UMcAdpCG9 xzhNe7Cqw8eaVkE CZeNq3xrx3nMsLN KmHGNWuEp5mY9j9 d8BzA27GrajUw4c Tt8Qm8x7kRk2y3Z TquJzdx2Z7A4UbA
vjBP1ecaHgMLuZh jbZaJY1BquG1g8U LhG67u1A6MftHpA meNoG6LcLJasnVy wCY2C3gjN85RxFK aCyG4z4oWmsvZAd foAzVTVKGe1KwBs
qP2kZJUchY1Rx2o pSxUjKphrFtERgb mKUCNdzXmLt7dZK QyRZB2ymdsqdwN1 kwpVPxHCsgyReyU dLGKs5rUsRTypeJ 5m1Ni8LYXoDk9fT
97dMM4dpaanv6Ey zo9TFXK95s1Rh5x j6spbLdBN1DWwKz q3hSGxDgNTPsTVW WZuhGaFxbvWBin3 UU2CJsTWMQV33RH e7JC5ePbzrbipEF
i22aY6R2rfV7bcA Riz5HNDNTcbGcab c3sbA1zaZ4WVC4u eiTn7qBN7zxtTmD EGfseyKnHtAM8Gj jNbPWXjA43WHmAq BR8tk7TuvQ4UdHt
gDdPKxu3B8oLPsu qLkKZXCx8tttSBc RXuxUrSCmc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7QR mMJFRs3. ENDSLATEPACK.
Transaction posted
Transaction finalized successfully
/Users/workstation/.grin/main/slatepack/3b9e526a-9f30-4ea2-86ae-4220e4f52c95.S3.slatepack

Slatepack data follows.

--- CUT BELOW THIS LINE ---

BEGINSLATEPACK. 22v2P12JXrX7h8C 8Xrroe8bgJs3Ryo vv2yG2t4bBriWDp yxHy8yUUFyUgwnf gAZ4ULmvSSz7HQ5 jDnFjcNUJCiGGBc
VBQJb2WmUK4CCmt HFdtj6eJW1wyENg 3Dvauvp5mjbmAZ8 QiasTwNyrGMj7jK PdWDffsoQnEKNUM 7EgSoGBAoEsAdjP vA4dnB2jsGjXzoH
iuZnN1e3Weq7tfa SYiUSYpqfZ6mbAG jS6qfhvarB5LXq3 pzqdX9iM2yAcA3z qAbk4y8M4SMiAe2 CcpmtHHdoWTFeCC ZJnfLu6ttvZv59J
7NFXZMwD9LKCi9u UpaNJaLY2xVjPGc RuQndkDh4XfRZEd fhhPvHfffXVZ3V2 17aSqr9zxaSfgGq DRQSnVPV7jgSqSv SGb572JZj1MnGQB
vFWCiYqQdrQFuUZ gzUCUGpPBfk7Czh VboLkSZf98tfHS3 jrreXqn5bh2c1u6 DMyjMicC64ms91g qoHdbufGAqSh3yG 9cnAY81VVcinwPh
HtktFJCQGAQk6ZW 8zLg5WsN3RrNESW xeyW8Dp1rcXbmpF mXcY7dbTJLG16GB UHdNijXaDnDT8xH iXa55W1X6qYuzwL sa5sBSc4ucBWSvb
mAqAFAGp5119gj5 LuZqeBUZAK67pAr LbZamo3JogKza5e 5DZ2F4xt5NzWkPL tiM4ignxYzkvgKc riw4YeEtep8qoSJ hohQBohtKzjwTda
3VRH59XUAZ84FzN dPcGtKK1uHbP4if k2d2VMX5yN6r3XA DPHe8P5DADTvjaG zwLA5xDDbAdHGUT kP8jUwRsiN3bEpp 4PsXPVCh7CYv3Z7
9WQcAcSHVPk9gfR cNYJvudxxo7DqrA x8cEEZNcDF26TUc u7nRCADdnEu8Rpm 9Dais5Evn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jC9vc7J YawsGtZDsRJWbYu p3RBve5ZrUCJeDS GaJDTnzaYxyQcSi
WHNLPXarNieMVFY aGRZg1wuzdZsyuN MY867biJt4YjWy9 AUP48uyjLrvqWzu ooQsKXepH7JWZbg zrgE1PVHug7hBp6 sZ7a6NM98hTesMz
iFyG9NJ3z492fjJ 9RMTfw417JABugg 8pwp9bppePkeoc3 FqK1grSnHYSgiiP w1Vzc417WGvXTmr JxUjJW9hmBKFknf jUPiGd81QPw9Z8E
U96Z4BiBCkxCQ7T mC7hWbwE4TMtoi8 uSPCVffb1EiRKN7 nGe6fRKpdTTqxtS jnXEDUjEG1edcLF EJYyHHuFj5HuNDg xz22PdWQBPUeFYK
CV6rV4Dca2Foh8f tCUbqCdBBTdigv9 VDF6TXNhEhhCoT8 rRaRYjFjebFQtDY pb9hBPXRXVXaq7R B5C3XJqktN9Nqsb kCzvQJGXkR3bw3j
orKLQFLefuRWXHT wZLBpNbqHnPxofH Ut5bntfqYNdNAW9 B1U4nRbHXjFYxHT YSmKrZ6GY24AogD Ck5fa9eRqdwYujP AYmXXxEmRfp828j
LafSaXTiNGSFGJr 9JZnkDvYq5EEdZh 6gVdpCmRDf7Bt3T ALtoAoGTsNrvXei FEka4HpXKiNbF5T ifghJEUkPEPtcU4 qjHKYjdbLrV83Lf
goePs2EzLhShbK4 9VChcfx5oiD5cAh CzP6rwjEfgmbZ9A GvXvReJbJdQwNSq eVhCMwsLCwfEccB cF3GtyDcgQN2ZT3 KJjJyGyQUTS9NKi
ZFYk7hM22goUZhb tQFH4CWVgom4Eus idZtH. ENDSLATEPACK.

--- CUT ABOVE THIS LINE ---

Slatepack data was also output to

/Users/workstation/.grin/main/slatepack/3b9e526a-9f30-4ea2-86ae-4220e4f52c95.S3.slatepack

The slatepack data is NOT encrypted

Command 'finalize' completed successfully
mojitoo commented 3 years ago

for the second flow, i found a bug @marekyggdrasil . i will send you a secret gist link

marekyggdrasil commented 3 years ago

@chandrashekar10 can you please help reproducing? @mojitoo found some problems and he is using Catalina, my wallet doesn't even run since I upgraded to Catalina due to this issue https://github.com/mimblewimble/grin-wallet/issues/554

I saw here you have Mojave and already appropriate testing setup, leave a thumbs up if you are interested and I'll assign you as well and of course you will also be rewarded

marekyggdrasil commented 3 years ago

I assign myself as well, but just to be clear, I am not participating in the challenge, I will just reproduce the results on Linux so that we have Catalina vs Mojave vs Linux.

chandrashekar10 commented 3 years ago

Environment

           Computer Model:  MacBook Air 2019 model
           Operating system: macOS Mojave version 10.14.6
           Rustup version:  rustc 1.48.0 (7eac88abb 2020-11-16)
    Clang version:  clang version 11.0.0
                  Target: x86_64-apple-darwin18.7.0
                  Thread model: posix
    Open SSL:    LibreSSL 2.6.5    

I have two wallets

  1.   Grin-wallet which is also the default wallet
  2.   Newwallet which is a local wallet created in the local directory “new wallet”

The absolute paths of the two wallets are

  1.  For the default wallet:  /Users/chandrashekar/grin-wallet/target/release
  2.  For the second wallet:   /Users/chandrashekar/newwallet  

I can reach the default wallet grin wallet from any directory without any problem (a) When I am in the grin-wallet folder I could reach the wallet without any problem

 Chandrashekars-MacBook-Air:release chandrashekar$ pwd
/Users/chandrashekar/grin-wallet/target/release
Chandrashekars-MacBook-Air:release chandrashekar$ ./grin-wallet info
Password: 
20201220 10:56:11.502 WARN grin_wallet_libwallet::api_impl::owner_updater - Scanning - 0% complete
20201220 10:56:12.512 WARN grin_wallet_libwallet::api_impl::owner_updater - Scanning - 99% complete
20201220 10:56:12.566 WARN grin_wallet_libwallet::api_impl::owner_updater - Scanning - 99% complete
20201220 10:56:12.567 WARN grin_wallet_libwallet::api_impl::owner_updater - Scanning Complete  

____ Wallet Summary Info - Account 'default' as of height 1010050 ____

Confirmed Total                  | 4.977000000 
Awaiting Confirmation (< 10)     | 0.000000000 
Awaiting Finalization            | 0.000000000 
Locked by previous transaction   | 0.000000000 
-------------------------------- | ------------- 
Currently Spendable              | 4.977000000 

Command 'info' completed successfully 

I could see the 4.97 grin I hold.

(b) Now I change my path to the Downloads directory

 Chandrashekars-MacBook-Air:~ chandrashekar$ cd Downloads 
 Chandrashekars-MacBook-Air:Downloads chandrashekar$ pwd
 /Users/chandrashekar/Downloads  

Then I check with the command grin-wallet info command

Chandrashekars-MacBook-Air:Downloads chandrashekar$ grin-wallet info
Password: 
20201220 11:09:07.058 WARN grin_wallet_libwallet::api_impl::owner_updater - Scanning - 0% complete
20201220 11:09:08.019 WARN grin_wallet_libwallet::api_impl::owner_updater - Scanning - 99% complete
20201220 11:09:08.048 WARN grin_wallet_libwallet::api_impl::owner_updater - Scanning - 99% complete
20201220 11:09:08.049 WARN grin_wallet_libwallet::api_impl::owner_updater - Scanning Complete 

    ____ Wallet Summary Info - Account 'default' as of height 1010050 ____

    Confirmed Total                  | 4.977000000 
    Awaiting Confirmation (< 10)     | 0.000000000 
    Awaiting Finalization            | 0.000000000 
    Locked by previous transaction   | 0.000000000 
    -------------------------------- | ------------- 
    Currently Spendable              | 4.977000000 

    Command 'info' completed successfully. 

So I can reach the grin-wallet from outside the ./grin-wallet folder. I have tested two condition here using (a) I show I can reach the wallet from within the ./grin-wallet folder and using (b) I show that I could access it from outside the ./grin-wallet folder.

Now to check the second wallet in the local directory called newwallet.

 Chandrashekars-MacBook-Air:~ chandrashekar$ cd newwallet
Chandrashekars-MacBook-Air:newwallet chandrashekar$ grin-wallet info
20201220 11:18:34.148 ERROR grin_wallet_impls::node_clients::http - Error calling get_version:  ResponseError error: 
    Cannot parse response
20201220 11:18:34.148 ERROR grin_wallet_impls::node_clients::http - Unable to contact Node to get   version info: 
    Client Callback Error: Error calling get_version: ResponseError error: Cannot parse     response
Password: 
20201220 11:18:45.486 ERROR grin_wallet_impls::node_clients::http - Error calling get_tip:  ResponseError error: 
    Cannot parse response
20201220 11:18:45.486 WARN grin_wallet_libwallet::api_impl::owner_updater - Updater Thread unable   to contact node 

 ____ Wallet Summary Info - Account 'default' as of height 1010032 ____

 Confirmed Total                  | 0.000000000 
 Awaiting Confirmation (< 10)     | 0.000000000 
 Awaiting Finalization            | 0.000000000 
 Locked by previous transaction   | 0.000000000 
 -------------------------------- | ------------- 
 Currently Spendable              | 0.000000000 

WARNING: Wallet failed to verify data against a live chain. The above is from local cache and only valid up to the given 
height! (is your `grin server` offline or broken?)
Command 'info' completed successfully. ‘’’

We can see the contents of the local wallet.
But from the warning messages we can see that the local Wallet is not connected to the node.
(This could possibly be a bug).

marekyggdrasil commented 3 years ago

I finished working on reproducing the test and @chandrashekar10 also sent me his findings in a secret gist repository. Great work everyone!

marekyggdrasil commented 3 years ago

@mojitoo and @chandrashekar10 I forgot to ask, can you please provide versions of your wallets?

chandrashekar10 commented 3 years ago

The version of wallets used in my test

The first wallet grin-wallet version is

Chandrashekars-MacBook-Air:release chandrashekar$ ./grin-wallet -V
grin-wallet 5.0.0-beta.3

The second wallet newwallet version is

Chandrashekars-MacBook-Air:newwallet chandrashekar$ grin-wallet -V
grin-wallet 5.0.0-beta.3
mojitoo commented 3 years ago