node icon indicating copy to clipboard operation
node copied to clipboard

TON.TON ZRC-20 gasLimit should match contract const

Open swift1337 opened this issue 9 months ago • 4 comments

zq fungible list-foreign-coins --output json | jq '.foreignCoins[] | select(.symbol | contains("TON"))'
{
  "zrc20_contract_address": "0x54Bf2B1E91FCb56853097BD2545750d218E245e1",
  "asset": "",
  "foreign_chain_id": "2015141",
  "decimals": 9,
  "name": "ZetaChain ZRC20 TON Testnet TON",
  "symbol": "TON.TON",
  "coin_type": "Gas",
  "gas_limit": "21000", // should be changed
  "paused": false,
  "liquidity_cap": "0"
}

But in GW contract it's 17500: https://github.com/zeta-chain/protocol-contracts-ton/blob/053a6fd7fc1d5e7604a2359d5a06569aba0640fe/contracts/gateway.fc#L35

swift1337 avatar Mar 06 '25 12:03 swift1337

@morde08 bumping this

swift1337 avatar Mar 13 '25 21:03 swift1337

AFAIK now this is configured in ZRC20, rather than in x/fungible cc @lumtis

swift1337 avatar Mar 14 '25 15:03 swift1337

Yes, the value in the foreign coin is not used at all, this value has been overlooked for a long time. I added the PR to deprecate the field but this would actually make more sense to just remove it since client should not read this value at all

lumtis avatar Mar 14 '25 15:03 lumtis

@swift1337 So we'll eventually remove all of the gas_limit fields anyway so this issue can be closed yeah?

morde08 avatar Mar 14 '25 16:03 morde08