grin-wallet: Can't Deserialize slate...?

grin-wallet send -m http -d https://grin.hotbit.io/353*** 1.64

This is a correct command, and this happened:

Wallet command failed: LibWallet Error: Can't Deserialize slate

Grin: 1.1.0 Grin-wallet: 1.1.0 OS: MacOS Mojave 10.14 Beta (18A377a)

About this issue

  • Original URL
  • State: closed
  • Created 5 years ago
  • Reactions: 1
  • Comments: 17 (4 by maintainers)

Most upvoted comments

Actually, it’s not that. I figured out the syntax Poloniex is expecting and what exactly fails, and then manually edited the .json produced by 1.1.0 to “fix” it for Poloniex deposits. Can confirm that the following works - i just sent 1.0 GRIN to Poloniex using a mangled slate file:

The problem is that 1.1.0 is outputting .tx.body.kernels[].features="Plain", and .tx.body.kernels[].lock_height=0 and also .lock_height=0

Poloniex expects .tx.body.kernels[].features="HeightLocked", and .tx.body.kernels[].lock_height=.height and also .lock_height=.height

The following small shell script should work (use at your own risk – though the worst it could happen is Poloniex saying “invalid file” or you not being able to finalize the tx, in which case you can just cancel it)

#!/bin/bash
height=$(grep -Po '(?<="height":)\d+' "$1")
sed -E 's/"kernels":\[\{"features":"Plain"/"kernels":\[\{"features":"HeightLocked"/;s/"lock_height":0/"lock_height":'$height'/g' "$1"

save the above into uncrap-polo.sh then produce your slate file using grin-wallet -m file -d polo.tx -v 1 1.0 (NOTE: the -v 1 is important!) then mangle it using bash uncrap-polo.sh polo.tx > polo-uncrapped.tx

You’re welcome, Poloniex … EDIT: and I’m taking @DevidBurkett’s suggestion 😃 feel free to send me some ETH or BTC:

  • 0x12B3AA96c9C093ceF445dC49155fFb5330ABFc6c
  • 3Nqmz8tZoHM4p8WfCheqYqKLBuV5SN9ZBu

p.s. Or patch the grin-wallet code to do the above … I was too lazy and went for the yucky option

Great find! Send Poloniex a bill for your work.

Haha … ok, I edited my post above and added my ETH and BTC wallets. Let’s see if Poloniex is up for a publicity stunt 😄

These are exchange issues (which we take some responsibility for). Please see the announcement regarding these kinds of issues here: https://www.grin-forum.org/t/addressing-recent-transaction-difficulties/5339

Also, tell all your friends and family to update to Grin v2.0.0 as soon as it’s available!

Well, Poloniex seems totally screwed right now … 1.0.2 deposits no longer work either.

Trying http gives:

grin wallet send -d "https://poloniex.com/public?currency=GRIN&command=createDeposit&id=6b21bfcb-9b24-493a-858c-659e1ecc5c7a" 50.0
Password:
20190614 21:33:38.205 ERROR grin_wallet::adapters::http - Posting transaction slate (is recipient listening?): ResponseError error: Cannot parse response
Wallet command failed: LibWallet Error: Client Callback Error: Posting transaction slate (is recipient listening?): ResponseError error: Cannot parse response

And trying uploading a slate file gives: