Skip to content
This repository has been archived by the owner on Nov 15, 2023. It is now read-only.

Stack overflow in tokio-runtime-worker in fork-tree implementation #9990

Answered by andresilva
nazar-pc asked this question in Q&A
Discussion options

You must be logged in to vote

The current implementation of BABE keeps all "open" epoch data in an in-memory data structure. Any epoch that has not been finalized is considered "open" since we could in theory build a fork on top of it. This in-memory data structure is the fork-tree and it is currently implemented as a recursive data structure. If a chain doesn't have any finality then this data structure will grow indefinitely and since it's currently recursive it will eventually lead to stack overflows. Even if it was rewritten to be iterative it would eventually lead to other problems like performance regressions (since it grows indefinitely). Since you don't have a finality gadget in your chain I would suggest that…

Replies: 3 comments

Comment options

You must be logged in to vote
0 replies
Comment options

You must be logged in to vote
0 replies
Comment options

You must be logged in to vote
0 replies
Answer selected by nazar-pc
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
3 participants