Metamask rpc error: execution reverted


I got this error after clicking a button to interact with a contract approve function, but instead of getting a contract call, I got no call but this error in my console. Please help.

You have to double check the parameters. Did the transaction made it to the chain or it was not even sent to the chain?

It did during the 1st test of the dApp, but when trying it the 2nd time the button freezed and the transaction was not sent

What do you mean with trying it the second time?

Testing my dApp again to make sure it’s working smoothly after clicking the button, then getting the approval contract call has it did during the 1st Testing of the dApp…

If you did one approval, what should happen second time?

The 1st approval was confirmed and the spender spent on behalf of the owner successfully, but clicking on the button again after the success of the 1st test, it didn’t send any contract call of any such, but pulled up that error in my browser console

If the tokes were spent, what is left to approve?

Is it one time the approve function can be called on a dApp after a successful transaction?

It depends on the amount that is transferred and on the account that is approved.

I’m sorry, please can you explain this for me to understand?

Can you explain what you did in details?
How many tokens the wallet address has, how many were approved, how many were transferred, how many remained in that wallet.

The wallet had 17 usdt, and 15 usdt was approved and transferred to the approved wallet leaving the owner wallet with a couple of tokens… then I sent back the 15 usdt to the owner wallet so I can try it out again. That was were I got the error message

Can you double check that current wallet has 17 usdt?
How much do you try to approve now?

Yes the owner wallet has the 17 usdt, and I tried to approve 15 usdt

Is it that after spending the approved amount of token successfully, and the owner wallet still has more than the 15 usdt that was approved in his wallet, should he go back and click on the approve button or can the spender spend the approved token without him clicking the button again?

Who spent the approved amount?

You should be able to approve anytime what you have in the wallet. Even if another approve was called before.

The receiver wallet, on my other mobile wallet device

But this isn’t working on my end. It stops after a successful transaction spent. Tried it on different wallet, its the same thing, stops after a successful txn