Skip to content

Commit 47e5c9b

Browse files
author
Michael Hammann
committed
fix: make sure spawnerrors are detected for spawn childs
1 parent 521ba37 commit 47e5c9b

File tree

1 file changed

+5
-0
lines changed

1 file changed

+5
-0
lines changed

supervisor/rpcinterface.py

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -297,7 +297,12 @@ def startProcess(self, name, wait=True):
297297
if child.state is not (ProcessStates.STARTING or ProcessStates.RUNNING):
298298
self.startProcess(child.group.config.name + ':' + child.config.name)
299299
else:
300+
self.supervisord.reap()
301+
if child.spawnerr:
302+
child.state = ProcessStates.FATAL
303+
raise RPCError(Faults.SPAWN_ERROR, name)
300304
child.transition()
305+
301306
msg = ("waiting on dependee process {} to reach running state - currently in {}"
302307
.format(child.config.name, getProcessStateDescription(child.state)))
303308
self.supervisord.options.logger.warn(msg)

0 commit comments

Comments
 (0)