nimbus-eth2
nimbus-eth2 copied to clipboard
Consistently FATAL before crashing
We have a couple of asserts to catch logic bugs that should never happen, for example https://github.com/status-im/nimbus-eth2/pull/1860#discussion_r503362155
Just in case they happen, we want to make sure that those are logged even when Nimbus is working without a CLI for example when logging to json.
This requires either use a fatal logging before doAssert or introduce something like fatalAssert that does both.
Additionally we might want FATAL log to automatically capture the stacktrace.
This seems reasonable as a goal. I'm in favor of ensuring that the easy thing is correct, i.e. something like a fatalAssert.