πŸ§™β€β™‚οΈ
Acala EVM+ Documentation
Acala WikiAcalaSwapHoma Liquid Staking
  • Getting started
  • πŸ’‘General
    • About Acala EVM+
    • Security considerations of developing in Acala EVM+
  • 🌐Network
    • Network configuration
    • Network setup
      • Local development network
      • Connecting to a public network with local RPC node
    • Predeployed smart contracts
      • Details
    • ACA token
    • Gas parameters
  • πŸ› οΈTooling
    • Tooling
    • Faucet
    • RPC adapter
    • Chain explorer
    • MetaMask
      • Connect to the network
      • Simple transactions
    • EVM playground
      • Deploy smart contracts
      • Interacting with smart contracts
    • Remix IDE
      • Deploying a smart contract
      • Interacting with the deployed smart contracts
  • πŸŽ“Examples
    • Examples
  • ✨Special features
    • Special features
    • Using polkadot wallet to interact with EVM+
    • Batch EVM transactions
  • πŸ’»Applications
    • Acala Multichain Asset Router
  • πŸ”ŽMiscellaneous
    • FAQs
    • Common errors
    • ETHDenver
    • Request support
    • Feedback or suggestions?
Powered by GitBook
On this page
  • when do I need to provide subquery url for eth-rpc-adpater or EvmRpcProvider?
  • why tx failed after I manually changed gas params in metamask?
  • why metamask tx doesn't confirm with local mandala?
  • I have balance in metamask, but transfer failed
  • tx failing reason not showing in blockscout
  • how to check if a transaction is finalized?

Was this helpful?

  1. Miscellaneous

FAQs

PreviousAcala Multichain Asset RouterNextCommon errors

Last updated 1 year ago

Was this helpful?

when do I need to provide subquery url for eth-rpc-adpater or EvmRpcProvider?

short answer

you need it when you ...

  • need to query for historical logs or tx receipts that exist before you start the provider or rpc adapter

  • OR need to query for logs or tx receipts that's older than MAX_CACHE_SIZE, which defaults to 200.

explanation

Transactions and logs from unfinalized blocks only live in cache, so new transactions will usually be in the cache first (for a couple blocks), then live in both the cache and the subquery, later, after the cache expires, they only live in subquery.

Developers who run a mandala node and eth-rpc-adaptor locally, usually won’t need to start any subquery or database services for testing, since new transaction receipts and logs will be in cache and findable without subquery.

For simple local testing setup, we can set a large MAX_CACHE_SIZE for rpc adapter, such as 10000 blocks. So even without subquery, we should be able to query for receipts and logs for as many as 10000 blocks.

why tx failed after I manually changed gas params in metamask?

why metamask tx doesn't confirm with local mandala?

Metamask will sometimes cache the nonce locally, which is used to infer next tx nonce. For example, if we send a tx with nonce 3, metamask will set nonce 4 for next tx. However, after we restart the local mandala node, all accounts are reset and the nonce is back to 0, but metamaks doesn't know it!

As a result, the account with nonce 0 send a tx with nonce 4, which won't be mined and got stuck!

To solve this, we need to reset metamask after restarting local Mandala, so the nonce and cache will be cleared: settings => advanced => reset account. Or we can simply manually override the nonce to 0 for the first metamask tx after restarting the network.

I have balance in metamask, but transfer failed

Metamask shows total balance, which might include non-transferable balances. For example, if some of your ACA is staking, they will still show in metamask, but can't be transfered.

tx failing reason not showing in blockscout

In this case ReserveStorageFailed means account balance not enough.

how to check if a transaction is finalized?

there are 2 ways:

  • use eth_getBlockByNumber with finalized block tag to get the latest finalized block number, and compare the tx block number with it.

  • use EVM+ specific RPC calls: eth_isTransactionFinalized or eth_isBlockFinalized.

Acala EVM+ uses encoded gasPrice and gasLimit, so manually inputting random gas parameters might fail to decode. Please refer to section for detailed explanations.

We can check the transferable balance in the Accounts section in

Every EVM+ transaction is essentially a substrate transaction, so we can find more details about it in .

For example, for , we can copy and paste the tx hash into the , which takes us to the , the exact error should show up in the bottom Events section.

πŸ”Ž
gas parameter
this failing tx
Acala Subscan
tx details page
polkadot.js app
substrate chain explorer
Cache vs. SubQuery representation
tx failed reason