babylonchain / babylon

Main repo for Babylon full node
https://babylonchain.io
Other
234 stars 165 forks source link

feat(jailing): Identify inactivity upon EndBlocker #681

Closed gitferry closed 3 months ago

gitferry commented 3 months ago

This PR (part of #682) is to impelement liveness handler within EndBlocker. Some notable changes:

gitferry commented 3 months ago

One note though, given that inactivity is purely informational flag (without any penalies) which will probably be triggered when fp misses his vote, maybe it makes sense to bring this flag to false after next successful vote instead of having separate message ? This can be done in separate pr though.

@KonradStaniec Good point. For story 1, we don't need to send a separate message to set the inactive to false. But I don't think we should set it to false upon next successful vote. It should also depend on the same detection algorithm. Specifically, we can set it back to false if the missed block counter is below the threshold and the inactive was set to true. Will implement this in a separate PR