aboutsummaryrefslogtreecommitdiff
path: root/jb/flow
diff options
context:
space:
mode:
authorstuppie2026-04-11 11:05:44 -0600
committerstuppie2026-04-11 11:05:44 -0600
commit588d4063de74d6f435cfab611328e802bce8df9a (patch)
treed52ce662924df82673b28c694b95cbb19090645a /jb/flow
parent67983224fbe5a33bd7bf8ea8c134b27f1afdda8a (diff)
downloadamt-jb-588d4063de74d6f435cfab611328e802bce8df9a.tar.gz
amt-jb-588d4063de74d6f435cfab611328e802bce8df9a.zip
reject_assignment try to continue (it might already be rejected but not updated in db)
Diffstat (limited to 'jb/flow')
-rw-r--r--jb/flow/assignment_tasks.py5
1 files changed, 3 insertions, 2 deletions
diff --git a/jb/flow/assignment_tasks.py b/jb/flow/assignment_tasks.py
index b678f44..6bda96b 100644
--- a/jb/flow/assignment_tasks.py
+++ b/jb/flow/assignment_tasks.py
@@ -239,12 +239,13 @@ def reject_assignment(
amt_assignment_id=amt_assignment_id, msg=msg
)
if res is None:
- # We failed to reject this assignment. Will this happen?
+ # We failed to reject this assignment. This happens if the assignment
+ # is already approved or already rejected.
emit_error_event(
event_type="failed_to_reject_assignment",
amt_hit_type_id=amt_hit_type_id,
)
- raise Exception(f"Failed to reject assignment: {amt_assignment_id}")
+ logging.exception(f"Failed to reject assignment: {amt_assignment_id}")
# We just rejected this assignment, get it from amazon again
assignment = amtm.get_assignment(amt_assignment_id=amt_assignment_id)