status-im / nimbus-eth2

Nim implementation of the Ethereum Beacon Chain
https://nimbus.guide
Other
516 stars 222 forks source link

VC: doesn't clean up DB connection on ctrl-c #3705

Open arnetheduck opened 2 years ago

arnetheduck commented 2 years ago
ERR 2022-06-04 22:04:11.007+02:00 Unable to check beacon node's status       error_name=RestCommunicationError error_message="Communication failed while sending/receiving request, http error [HttpConnectionError]: Could not connect to remote host" endpoint="localhost:11101 [Nimbus/v22.5.1-f8b5d0-stateofus]"
^CTraceback (most recent call last, using override)
/home/arnetheduck/status/nimbus-eth2/vendor/nim-websock/websock/types.nim(372) main
/home/arnetheduck/status/nimbus-eth2/vendor/nim-websock/websock/types.nim(365) NimMain
/home/arnetheduck/status/nimbus-eth2/beacon_chain/nimbus_validator_client.nim(205) main
/home/arnetheduck/status/nimbus-eth2/vendor/nim-chronos/chronos/asyncloop.nim(1074) waitFor
/home/arnetheduck/status/nimbus-eth2/vendor/nim-chronos/chronos/asyncloop.nim(704) poll
/home/arnetheduck/status/nimbus-eth2/vendor/nim-chronos/chronos/ioselects/ioselectors_epoll.nim(379) selectInto
/home/arnetheduck/status/nimbus-eth2/vendor/nimbus-build-system/vendor/Nim/lib/system/excpt.nim(610) signalHandler
SIGINT: Interrupted by Ctrl-C.

the slashing db should be closed before exit

cheatfate commented 2 years ago

This issue fully fixed on Linux, BSD, MacOS but still present on Windows.

zah commented 1 year ago

It's difficult for me to see the connection between the cited error message / stack trace and the original issue title. Can you provide more details regarding this problem? This may be relevant to the recent discussions about enabling the --panics:on mode.

arnetheduck commented 1 year ago

It's difficult for me to see the connection between the cited error message / stack trace and the original issue title.

In earlier versions of the VC, pressing ctrl-c led to that call stack - there was no signal handler at all for shutting down, ie every exit ended with a "crash" like that.