3
0
mirror of https://github.com/jlu5/PyLink.git synced 2024-11-24 03:29:28 +01:00

control: log the name of the PID file on shutdown

This commit is contained in:
James Lu 2017-07-12 22:17:00 -07:00
parent 561319bc57
commit d57e141fbc

View File

@ -25,11 +25,12 @@ def _print_remaining_threads():
def _remove_pid():
# Remove our pid file.
log.info("Removing our pid file.")
pidfile = "%s.pid" % conf.confname
log.info("Removing PID file %r.", pidfile)
try:
os.remove("%s.pid" % conf.confname)
os.remove(pidfile)
except OSError:
log.exception("Failed to remove PID, ignoring...")
log.exception("Failed to remove PID file %r, ignoring..." % pidfile)
def _kill_plugins(irc=None):
log.info("Shutting down plugins.")