Starting with the node-template, I switched my chains block authoring from Aura to Babe, which compiles fine but does not manage to finalize any blocks. I suspect it's a wrong genesis configuration. The RPC call for grandpa roundState shows the following:
{"setId":0,"best":{"round":1,"totalWeight":2,"thresholdWeight":2,"prevotes":{"currentWeight":1,"missing":["5GoNkf6WdbxCFnPdAnYYQyCjAKPJgLNxXwPjwTh6DGg6gN3E"]},"precommits":{"currentWeight":0,"missing":["5FA9nQDVg267DEd8m1ZypXLBnvN7SFxYwV7ndqSYGiN9TTpu","5GoNkf6WdbxCFnPdAnYYQyCjAKPJgLNxXwPjwTh6DGg6gN3E"]}},"background":[]}
Not sure what I can extract from that.
My question is which part of the code is responsible for proper finalization.
Unexpected epoch change
error? Please include the errors coming from the terminal logs if there are any. This could be what you're looking for: github.com/paritytech/substrate/issues/4464