Skip to content
This repository has been archived by the owner on Dec 16, 2022. It is now read-only.

Hardcoded gas limit of 250000 makes transactions fail for more complex tokens such as Digix Gold Tokens #144

Open
pascalvanhecke opened this issue Apr 18, 2018 · 0 comments
Labels
bug Something isn't working

Comments

@pascalvanhecke
Copy link

in

https://github.com/forkdelta/forkdelta.github.io/blob/4760275d2853dab199bd6b8da1cb87270852a63b/config/main.json

and

https://github.com/forkdelta/forkdelta.github.io/blob/71c508dbb6d21bf459bd051d34e39f5554645bac/config/testnet.json

the gas limits at line 18-22 are hardcoded at 250000

"gasApprove": 250000,
"gasDeposit": 250000,
"gasWithdraw": 250000,
"gasTrade": 250000,
"gasOrder": 250000,

For complex tokens like Digix Gold Tokens, this makes the transactions fail.

Example:

https://etherscan.io/tx/0x382b59f6bc625ef6d42e5913b034e17d7050eb826663050c0c2f70dbb07cc83e fails

But with a higher gas limit of 297745 the same transaction (slightly different second parameter, but that did not matter), the same transaction succeeds:

https://etherscan.io/tx/0xd2b1598590a5c25e9d6ae0767f9cd6ae885681b19ee028d4fe32d8329786a46a

Easy solution (not advisable): raise gaslimit for all tokens to 300 000.
More complex solution: make gaslimit configurable per token, in other words, in https://github.com/forkdelta/forkdelta.github.io/blob/4760275d2853dab199bd6b8da1cb87270852a63b/config/main.json extra gas limit parameters per token should override the default gas limit.

@freeatnet freeatnet added the bug Something isn't working label Sep 21, 2018
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

2 participants