Skip to content
Snippets Groups Projects
Commit dccd4175 authored by Charlotte Hausman's avatar Charlotte Hausman
Browse files

fix bug with queues dictionary access

parent 69e6611a
No related branches found
No related tags found
1 merge request!100fix bug with queues dictionary access
Pipeline #640 failed
...@@ -70,6 +70,7 @@ services/notification/notification.log ...@@ -70,6 +70,7 @@ services/notification/notification.log
**/coverage.xml **/coverage.xml
**/coverage.json **/coverage.json
pyproject.toml pyproject.toml
package-lock.json
# Ignore docker volume mount points # Ignore docker volume mount points
services/**/**/apps services/**/**/apps
......
...@@ -102,9 +102,10 @@ class CapabilityService(CapabilityServiceIF): ...@@ -102,9 +102,10 @@ class CapabilityService(CapabilityServiceIF):
== CapabilityStepType.PrepareAndRunWorkflow == CapabilityStepType.PrepareAndRunWorkflow
): ):
# Return capability engine to available state # Return capability engine to available state
self.queues[execution.capability.name].complete_execution( if self.queues:
capability_event.execution_id self.queues.get(execution.capability.name).complete_execution(
) capability_event.execution_id
)
if execution.current_step != len(step_sequence)-1: if execution.current_step != len(step_sequence)-1:
# Execution is not on its last step # Execution is not on its last step
...@@ -127,7 +128,7 @@ class CapabilityService(CapabilityServiceIF): ...@@ -127,7 +128,7 @@ class CapabilityService(CapabilityServiceIF):
self.enqueue_execution(execution, ExecutionPriority.Default.value) self.enqueue_execution(execution, ExecutionPriority.Default.value)
# Update execution record's state # Update execution record's state
execution.state = ExecutionState.Ready.name # execution.state = ExecutionState.Ready.name
self.capability_info.save_execution(execution) self.capability_info.save_execution(execution)
else: else:
# TODO: Logging # TODO: Logging
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment