6

When I first load my Dapp with testrpc the functionality doesn't work until I use the command truffle migrate --reset

Any ideas why?

  • When you start testrpc, it's a whole new blockchain (simulation) so previous migrations are absent. Truffle isn't aware of that, so --reset is part of the routine. One possible reason for it. – Rob Hitchens Feb 4 '17 at 22:01
  • Ok so it's normal to have to reset the migrations then? – ethereal Feb 6 '17 at 18:48
  • Its' normal for me. :-) – Rob Hitchens Feb 6 '17 at 18:57
3

This is because truffle remembers previous migrations you made but you are on a new test network. You can see registered contract addresses by running truffle networks.

You can delete these informations by running truffle networks --clean before truffle migrate.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.