Fix network issues causing Task to stop on status change even though no status change has occurred (#535)

This commit is contained in:
allegroai 2022-01-15 23:05:23 +02:00
parent e4df21ea52
commit 5953dc6eef

View File

@ -31,6 +31,10 @@ class TaskStopSignal(object):
# we use internal status read, so we do not need to constantly pull the entire task object, # we use internal status read, so we do not need to constantly pull the entire task object,
# it might be large, and we want to also avoid the edit lock on it. # it might be large, and we want to also avoid the edit lock on it.
status, message = self.task._get_status() status, message = self.task._get_status()
# if we did not get a proper status, return and recheck later
if status is None and message is None:
return None
status = str(status) status = str(status)
message = str(message) message = str(message)