workflows: really log invalid status detection (#23894)
This commit is contained in:
parent
c8a06c48f3
commit
579b1c17e3
|
@ -1700,15 +1700,14 @@ class WorkflowStatusItem(XmlSerialisable):
|
|||
return [previous_status]
|
||||
return []
|
||||
|
||||
try:
|
||||
return [x for x in self.parent.parent.possible_status if x.id == self.status]
|
||||
except IndexError:
|
||||
targets = [x for x in self.parent.parent.possible_status if x.id == self.status]
|
||||
if not targets:
|
||||
get_publisher().get_app_logger().error(
|
||||
'reference to invalid status in workflow %s, status %s, item %s' % (
|
||||
self.parent.parent.name,
|
||||
self.parent.name,
|
||||
self.description))
|
||||
return []
|
||||
return targets
|
||||
|
||||
def get_jump_label(self):
|
||||
'''Return the label to use on a workflow graph arrow'''
|
||||
|
|
Loading…
Reference in New Issue