Taraxa-project / taraxa-platform

2 stars 3 forks source link

Fix value to decimal on wrong conversion #603

Closed VargaElod23 closed 1 year ago

VargaElod23 commented 1 year ago

This makes revert messages to be wrong: https://testnet.explorer.taraxa.io/tx/0x64cd3b9082fe85670e0fe365e990ae0addf42cc6826dfc1854dede1e812e4eaa while the real revert reason is:

curl 'https://rpc.testnet.taraxa.io/' \                                                                     ─╯
  -H 'authority: rpc.testnet.taraxa.io' \
  -H 'accept: application/json, text/plain, */*' \
  -H 'accept-language: en-GB,en-US;q=0.9,en;q=0.8' \
  -H 'content-type: application/json' \
  -H 'origin: https://testnet.explorer.taraxa.io' \
  -H 'referer: https://testnet.explorer.taraxa.io/' \
  -H 'sec-ch-ua: "Google Chrome";v="119", "Chromium";v="119", "Not?A_Brand";v="24"' \
  -H 'sec-ch-ua-mobile: ?1' \
  -H 'sec-ch-ua-platform: "Android"' \
  -H 'sec-fetch-dest: empty' \
  -H 'sec-fetch-mode: cors' \
  -H 'sec-fetch-site: same-site' \
  -H 'user-agent: Mozilla/5.0 (Linux; Android 6.0; Nexus 5 Build/MRA58N) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/119.0.0.0 Mobile Safari/537.36' \
  --data-raw '{"method":"eth_call","params":[{"from":"8979b4ee5b34e406f6c43ab1828b860ec67d78a4","to":"8b2c4dced861ca885a49bdf10e54631da024ae60","gas":"0x2dc6c0","gasPrice":"0x1","value":"100000000000000000000000","data":"0xa694fc3a00000000000000000000000000000000000000000000152d02c7e14af6800000"},"0xa3a84"],"id":1,"jsonrpc":"2.0"}' \
  --compressed

So yeah, we don't need the hex transform