trufflesuite / ganache-ui

Personal blockchain for Ethereum development
https://www.trufflesuite.com/ganache
MIT License
4.65k stars 797 forks source link

ganache closed and reopen, the block height reset to zero, continue transactions failed #437

Closed 3for closed 6 years ago

3for commented 6 years ago

I'm now following the website below to try to use truffle and ganache in windows 10: http://truffleframework.com/tutorials/robust-smart-contracts-with-openzeppelin 1) I install & open ganache to start the development network, the block height is zero; 2) Using 'truffle migrate' to deploy the contracts on the development network successfully, the block height in ganache is 4; 3) made a token transfer successfully, the block height in ganache is 5; 4) close the ganache and reopen ganache, the block height is reset to zero! 5) I redeploy the contracts,, the block height changed to 4; 6) made a token transfer failed, for the height is not corresponding.("Error: the tx doesn't have the correct nonce. account has nonce of:4 tx has nonce of:5 at runCall") image

How can I fix this problem while using MetaMask to test?

3for commented 6 years ago

Got fixed to reset the MetaMask account. https://github.com/MetaMask/metamask-extension/issues/3629