cosmjs icon indicating copy to clipboard operation
cosmjs copied to clipboard

How to decode client getBlock(). txs. decodedTxRaw. signatures?

Open chaim-g opened this issue 3 years ago • 5 comments

chaim-g avatar Jan 14 '22 01:01 chaim-g

image After parsing tsx, I also need to get the txHash of this transaction, but I don't see the txHash after parsing it. The signatures field is the txHash of the transaction, right? Or is there something wrong with my understanding? Why has no one replied?

chaim-g avatar Jan 17 '22 02:01 chaim-g

@webmaster128 please

chaim-g avatar Jan 17 '22 02:01 chaim-g

The tx hash is simply sha256(txBytes), so you don't need to decode it at all in order to get the hash.

webmaster128 avatar Jan 17 '22 08:01 webmaster128

Why has no one replied?

GitHub is not a support channel and unfortunately there is no reliable support channel for CosmJS right now. Questions are answered depending on availablility and mood. Not a great solution, I know. But that's the reality.

webmaster128 avatar Jan 17 '22 08:01 webmaster128

@chaim-g have you solved this ? i have also same question .

bytesmix avatar May 22 '22 09:05 bytesmix