question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

PaymentInfo call throws 'Error decoding field Call'

See original GitHub issue

I’m creating two ApiPromise instances, one use to connect Kusama network and the other use to connect Polkadot network. When I use the two instances to call paymentInfo for estimate tx fee at the same time, then get error below:

RPC-CORE: queryInfo(extrinsic: Bytes, at?: BlockHash): RuntimeDispatchInfo:: 2: Unable to query dispatch info.: Error decoding field Call :: Authorship.0

my code:

const kusamaApi = new ApiPromise({ provider: kusamaProvider });
await kusamaApi.isReady;
const polkadotApi = new ApiPromise({ provider: polkadotProvider });
await polkadotApi.isReady;

const transfer = await kusamaApi.tx.balances.transfer("Efc2jfxwUVUrjCSs4t3o6QJU3R8xqtHpwDvhD2f1oKactFX", 1)
    .paymentInfo("Efc2jfxwUVUrjCSs4t3o6QJU3R8xqtHpwDvhD2f1oKactFX");

const transfer2 = await polkadotApi.tx.balances.transfer("136HWkbAAtk2YcPX41813HsTB58YrUdFT47fTqk4668c4Fkv", 1)
    // this call will get error
    .paymentInfo("136HWkbAAtk2YcPX41813HsTB58YrUdFT47fTqk4668c4Fkv");

Issue Analytics

  • State:closed
  • Created 3 years ago
  • Comments:7 (4 by maintainers)

github_iconTop GitHub Comments

1reaction
jacogrcommented, Sep 3, 2020

Fixed in 1.32.0-beta.12 and later. (Tested against the same script provided here)

1reaction
KanLeicommented, Sep 2, 2020

Yes, I have upgrade to API 1.31.2, still get the same error.

Read more comments on GitHub >

github_iconTop Results From Across the Web

Type error when querying data at block 705492 #167 - GitHub
toPromise() // The query blow will throw error await api.rpc.payment. ... Error decoding field Call :: CennzxSpot.0` } main();.
Read more >
polkadot-js balances.transfer throws error - Stack Overflow
In my webapp balances.transfer is throwing an error but staking. ... Error: createType(Call):: Call: failed decoding balances.transfer:: ...
Read more >
Mollie is throwinf an error - WordPress.org
I have installes Events manager pro and mollie Gateway. When i book an event with 2 plavces amount 1200 € it throws the...
Read more >
Transactions - polkadot{.js}
Assuming you are sending a tx via .signAndSend , the callback yields information around the tx pool status as well as any events...
Read more >
Payment Error Codes - ISN
CODE TEXT DESCIPTION I00001 Successful. The request was processed successfu... I00002 The subscription has already been canceled. The subscription has already been ca... I00003 The record...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found