[Calypso] [PATCH] Only import lockfile.pidlockfile when needed
Guido
agx at sigxcpu.org
Sun Jan 24 23:00:53 PST 2016
Debian Jessie python-lockfile 0.8 lacks it and a pidlockfile is not
always needed.
---
calypso.py | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/calypso.py b/calypso.py
index c3c1999..7d8c31b 100755
--- a/calypso.py
+++ b/calypso.py
@@ -38,7 +38,6 @@ arguments.
import daemon
import lockfile
-from lockfile import pidlockfile
import logging
import optparse
import os
@@ -149,6 +148,7 @@ if not options.daemon:
context = daemon.DaemonContext()
context.umask = 0o002
if options.pidfile:
+ from lockfile import pidlockfile
# Generate a pidfile where requested
context.pidfile = pidlockfile.PIDLockFile(options.pidfile)
with context:
--
2.7.0.rc3
More information about the Calypso
mailing list