polkadot-js / api

Promise and RxJS APIs around Polkadot and Substrate based chains via RPC calls. It is dynamically generated based on what the Substrate runtime provides in terms of metadata.
Apache License 2.0
1.07k stars 350 forks source link

Westmint block #5482732 can not be decoded #5734

Closed wliyongfeng closed 11 months ago

wliyongfeng commented 1 year ago

https://polkadot.js.org/apps/?rpc=wss%3A%2F%2Fsys.ibp.network%2Fwestmint#/explorer/query/5482732 PXyyRhbBw5

Imod7 commented 11 months ago

Same Issue

I can confirm that I see the same error message when requesting

either by :

Findings / Thoughts

This error message is triggered here so the call missing is in section = 5 and is the method with index 69 right ? Based on the docs, the section signifies the pallet of the extrinsic but in Westend Asset Hub I do not see any pallet with index 5 🤔. Maybe I am missing something.

Any ideas which method/call is causing the issue ?

Reproducing the error with pjs

Trying to reproduce the same error with pjs. After running this github gist code the error returned is the same as above

2023-10-23 15:17:35        API/INIT: westmint/9435: Not decorating runtime apis without matching versions: FungiblesApi/2 (1 known)
2023-10-23 15:17:35        API/INIT: westmint/9435: Not decorating unknown runtime apis: 0x8a8047a53a8277ec/1
2023-10-23 15:17:35             VEC: Unable to decode on index 2 createType(ExtrinsicV4):: createType(Call):: findMetaCall: Unable to find Call with index [5, 69]/[5,69]
2023-10-23 15:17:35        RPC-CORE: getBlock(hash?: BlockHash): SignedBlock:: createType(SignedBlock):: Struct: failed on block: {"header":"Header","extrinsics":"Vec<Extrinsic>"}:: Struct: failed on extrinsics: Vec<Extrinsic>:: createType(ExtrinsicV4):: createType(Call):: findMetaCall: Unable to find Call with index [5, 69]/[5,69]
Error: createType(SignedBlock):: Struct: failed on block: {"header":"Header","extrinsics":"Vec<Extrinsic>"}:: Struct: failed on extrinsics: Vec<Extrinsic>:: createType(ExtrinsicV4):: createType(Call):: findMetaCall: Unable to find Call with index [5, 69]/[5,69]
    at createTypeUnsafe (/Users/dominique/Documents/Parity/test-js/node_modules/@polkadot/types-create/cjs/create/type.js:54:22)
    at TypeRegistry.createTypeUnsafe (/Users/dominique/Documents/Parity/test-js/node_modules/@polkadot/types/cjs/create/registry.js:271:52)
    at RpcCore._formatOutput (/Users/dominique/Documents/Parity/test-js/node_modules/@polkadot/rpc-core/cjs/bundle.js:309:25)
    at RpcCore._formatResult (/Users/dominique/Documents/Parity/test-js/node_modules/@polkadot/rpc-core/cjs/bundle.js:147:20)
    at callWithRegistry (/Users/dominique/Documents/Parity/test-js/node_modules/@polkadot/rpc-core/cjs/bundle.js:168:25)
    at process.processTicksAndRejections (node:internal/process/task_queues:95:5)

and the line where the code breaks is (the getBlock call for the specific blockHash) :

const signedBlock = await api.rpc.chain.getBlock(blockHash);
bee344 commented 11 months ago

This should be closed by #5752

jacogr commented 11 months ago

Closing on the back of the comments. Feel free to re-open if there is another issue not solved by the PRs.

polkadot-js-bot commented 10 months ago

This thread has been automatically locked since there has not been any recent activity after it was closed. Please open a new issue if you think you have a related problem or query.