4

I'm trying to prepare a local parachain testnet. However, when I run two nodes at the same time, although the two nodes recognise each other no new blocks are added and I get this error:

Error with block built on 0x8d39cb0a86cceeeae7861dcc2b19fe9d8db94b8481ea50fd13093c7e632dc101: Import failed: Unexpected epoch change    

Any idea how to fix this?

1

1 Answer 1

2

I think this is an error from the relaychain, not the parachain.

I guess the reason is that your relaychain was stopping producing blocks for a long time. Which doesn't meet BABE requirement.

Try to clean the DB.

7
  • How do I clean the DB? Commented Aug 3, 2022 at 8:18
  • 1
    Just remove the data dir. If you specify the --base-dir or -d then there it is. If not, on Linux it will be ~/.local/share/<chain name>, on Mac it will be ~/Library/Application Support/<chain name>.
    – aurexav
    Commented Aug 4, 2022 at 0:52
  • or run with --dev which will implicitly use --tmp flag to use a fresh db each time.
    – Squirrel
    Commented Aug 4, 2022 at 5:55
  • IMHO --dev is not a good choice, as he is on relaychain env. --dev will build a brand new genesis state. Which may cause some syncing issues. But if --chain could override the --dev's default chain, that's fine.
    – aurexav
    Commented Aug 4, 2022 at 5:58
  • 1
    No, that's impossible. Unless you modify the consensus engine. BTW, you can use the latest version. No more unexpected epoch change in the future.
    – aurexav
    Commented Apr 7, 2023 at 3:20

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

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