Does anyone know that is there a difference between DOT / KSM / Westend transactions?
Context:
A common send/transfer transaction...
I can generate same pk and address for Dot and KSm and WST chains as the js tool does. Also can create and sign the ExtrinsicPayloadV4 for dot, and create the ExtringicTV4
And the only transaction is working is DOT...
The payload's differ a bit, e.g.:
specversion, transactionversion, genesis == blockhash (it comes from the chain's api)
the method is in both cases: section 5, index: 0
The problem:
when i try to submit the signed tx i got error stg like this from the node in case of KSM or WST chains:
{"code":1002,"message":"Verification Error: Runtime error:
Execution failed: Execution aborted due to trap: wasm trap: wasm `unreachable` instruction executed\n
WASM backtrace:\n\n
0: 0x506d90 - <unknown>!rust_begin_unwind\n
1: 0x42c4 - <unknown>!core::panicking::panic_fmt::h6314b5c91abe7349\n
2: 0x8cb3d - <unknown>!TaggedTransactionQueue_validate_transaction\n",
"data":"Runtime error: Execution failed: Execution aborted due to trap: wasm trap: wasm `unreachable` instruction executed\nWASM backtrace:\n\n
0: 0x506d90 - <unknown>!rust_begin_unwind\n
1: 0x42c4 - <unknown>!core::panicking::panic_fmt::h6314b5c91abe7349\n
2: 0x8cb3d - <unknown>!TaggedTransactionQueue_validate_transaction\n"
}
Any help would be appreciated.
04
for Polkadot it is on05
. (These needs to be retrieved from the metadata, it cannot be hardcoded since it will be different between chains and could even move, although that is now more unlikely). TL;DR Always retrieve the pallet and method indexes from the on-chain metadata.