Skip to content

Conversation

bh2smith
Copy link
Member

@bh2smith bh2smith commented Feb 21, 2025

Previously we would get the following viem error when attempting to get native asset token data:

Error fetching token decimals: ContractFunctionExecutionError: The contract function \"decimals\" returned no data (\"0x\").

This could be due to any of the following:
  - The contract does not have the function \"decimals\",
  - The parameters passed to the contract function may be invalid, or
  - The address is not a contract.

Contract Call:
  address:   0xEeeeeEeeeEeEeeEeEeEeeEEEeeeeEeeeeeeeEEeE
  function:  decimals()

Docs: https://viem.sh/docs/contract/readContract
Version: viem@2.22.11

@bh2smith bh2smith merged commit ae02114 into main Feb 21, 2025
1 check passed
@bh2smith bh2smith deleted the fixNativeAsset branch February 21, 2025 14:03
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant