Skip to content

Commit

Permalink
.
Browse files Browse the repository at this point in the history
  • Loading branch information
nathandf committed May 14, 2024
1 parent 0aca563 commit 5e66b5e
Showing 1 changed file with 2 additions and 4 deletions.
6 changes: 2 additions & 4 deletions src/api/src/backend/views/PipelineLocks.py
Original file line number Diff line number Diff line change
Expand Up @@ -103,10 +103,8 @@ def post(self, request, group_id, pipeline_id):
# pipeline lock attempt is the next in the queue. If so, update the
# pipeline lock's 'acquired_at' property
if str(pipeline_lock.pipeline_run.uuid) == str(competing_runs[0].uuid):
acquired_at = timezone.now()
pipeline_lock = PipelineLock.objects.filter(
uuid=pipeline_lock.uuid
).update(acquired_at=acquired_at)
pipeline_lock.acquired_at = timezone.now()
pipeline_lock.save()

# Set the message for the pipeline lock acquisition attempt
message = f"Lock not acquired. Locks ahead of '{str(pipeline_lock.uuid)}'"
Expand Down

0 comments on commit 5e66b5e

Please sign in to comment.