Terminate subprocesses right way on cronstop
This commit is contained in:
1 parent
87cf9307f0
commit
53e22fc31c
1 file changed
+4
-1
+4
-1
@@ -260,7 +260,10 @@ class cronlauncher(threading.Thread):
|
||||
shell=self.shell)
|
||||
_cron_subprocs.append(proc)
|
||||
(stdoutdata, stderrdata) = proc.communicate()
|
||||
_cron_subprocs.remove(proc)
|
||||
try:
|
||||
_cron_subprocs.remove(proc)
|
||||
except ValueError:
|
||||
pass
|
||||
if proc.returncode != 0:
|
||||
logger.warning(
|
||||
'WEB2PY CRON Call returned code %s:\n%s' %
|
||||
|
||||
Reference in new issue
Block a user