I’m running into some issues with metamask estimating the wrong amount of gas for a specific transaction for my Dapp. It needs around 130k gas to execute, but metamask (around 5% of the time) will set the gas limit to 50k, and I’ll get the out of gas revert because of it.
Is there a way for me, in my web3.js code, to tell metamask ‘you need 130k gas for this transaction’, so i never get the revert?
I try this but metamask ignores it, seemingly.
contract.methods.functionThatReverts(web3.utils.toWei((100000).toString(), ‘ether’)).send({from: accounts[0], gas:130000})