TestRPC/Ganache: the tx doesn’t have the correct nonce

Using MetaMask v3.14.1 you can reset your account as follow:

Resetting an Account In the Settings menu, MetaMask has a “Reset
Account” button. This button wipes the current account’s transaction
history, which is used to calculate the current account nonce.

enter image description here

Normal users should never have a reason to use this feature.

This is useful for developers who reset a test network but want to
continue using the same account, forcing MetaMask to believe this
network ID is a clean network in a fresh state.

Ref: http://metamask.helpscoutdocs.com/article/36-resetting-an-account

(Thanks to Tim Wu)

Old response:
Answer of yatskevich is correct.

However, for people how are using Truffle 4+ with “truffle develop”, you need to remove and reinstall MetaMask to get it work again, every time you run Truffle Develop!

This issue is addressed here:
https://github.com/trufflesuite/truffle/issues/681, here:
https://github.com/trufflesuite/ganache/issues/112, and also here: https://github.com/MetaMask/metamask-extension/issues/1999

In short they are working on it and in the mean time you need to reinstall MetaMask every time!

Leave a Comment