You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
The error you shared should throw when you attempt to send a transaction or interact with a smart contract but don't have enough native token balance to cover the cost of the interaction. It should not throw for a contract interaction that is just reading state, because there is no fee for reading the contract state.
Would you be able to provide a reproducible code sandbox where this issue is reproduced? If not, do you have steps for us to follow to reproduce this issue?
I created a sandbox here that makes a call to the Uniswap contract to get the balance of an account. The call properly returns even with a new user wallet because balanceOf is a view function and does not require gas. You may fork the demo to reproduce your issue.
โ Prerequisites
magic-sdk
)?๐ Description
I am receiving INSUFFICIENT_FUNDS when trying to use the signer of Magic's RPC provider.
Magic RPC Error: [-32603] Error forwarded from node: insufficient funds for gas * price + value"}, method="sendTransaction", transaction=undefined, code=INSUFFICIENT_FUNDS
๐งฉ Steps to Reproduce
const owner = new ethers.providers.Web3Provider(magic.rpcProvider as any);
๐ค Expected behavior
Getting the balance of this usually gas-less transaction.
๐ฎ Actual behavior
"Magic RPC Error: [-32603] Error forwarded from node: insufficient funds for gas * price + value"}, method="sendTransaction", transaction=undefined, code=INSUFFICIENT_FUNDS
๐ป Code Sample
[If possible, please provide a code repository, gist, code snippet or sample files to reproduce the issue.]
๐ Environment
magic-sdk
yarn
The text was updated successfully, but these errors were encountered: