You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Using the stop command results in a panic in the world saving logic (most likely because this hasn't been implemented but that's beside the point of this issue).
While ^C/SIGINT does not cause this crash and closes the server properly.
I'm mainly trying to highlight the difference in behaviour between the two shutdown methods.
Expected behavior
Centralise the logic of shutting the server down so there's no discrepancies between the server handling a stop command and it receiving a ^C/SIGINT/SIGTERM from the command line.
The text was updated successfully, but these errors were encountered:
I put that on the to do list already, I think we should use channels for something like that to send shutdowns when we need them. Also https://tokio.rs/tokio/topics/shutdown is useful
I've searched existing issues and couldn't find a duplicate.
Operating System
Any
Server Software Version/Commit
master
What happened?
The stop command has a fairly normal logic of stopping the server and handling everything:
Pumpkin/pumpkin/src/command/commands/cmd_stop.rs
Lines 31 to 36 in febbfd8
However the signal handler is missing these player kicking and saving steps:
Pumpkin/pumpkin/src/main.rs
Lines 258 to 266 in febbfd8
To Reproduce
Using the
stop
command results in a panic in the world saving logic (most likely because this hasn't been implemented but that's beside the point of this issue).While
^C/SIGINT
does not cause this crash and closes the server properly.I'm mainly trying to highlight the difference in behaviour between the two shutdown methods.
Expected behavior
Centralise the logic of shutting the server down so there's no discrepancies between the server handling a
stop
command and it receiving a^C/SIGINT/SIGTERM
from the command line.The text was updated successfully, but these errors were encountered: