File tree Expand file tree Collapse file tree 1 file changed +7
-7
lines changed
servers/fai-lambda/fai-scribe/src/utils Expand file tree Collapse file tree 1 file changed +7
-7
lines changed Original file line number Diff line number Diff line change @@ -150,14 +150,14 @@ async def run_editing_session(
150150 await update_session_status (editing_id , "active" )
151151 LOGGER .info (f"Transitioned new session { editing_id } from STARTUP to ACTIVE" )
152152
153- is_interrupted , receipt_handle = check_if_interrupted_via_sqs ( sqs_client )
154- if is_interrupted :
155- LOGGER . warning ( f"Session interrupted via SQS: { editing_id } " )
156- if receipt_handle :
157- sqs_client . delete_message ( receipt_handle )
158- if session_id is not None :
153+ if session_id is not None :
154+ is_interrupted , receipt_handle = check_if_interrupted_via_sqs ( sqs_client )
155+ if is_interrupted :
156+ LOGGER . warning ( f"Session interrupted via SQS: { editing_id } " )
157+ if receipt_handle :
158+ sqs_client . delete_message ( receipt_handle )
159159 await update_session_status (editing_id , "waiting" )
160- raise SessionInterruptedError (f"Editing session { editing_id } was interrupted" )
160+ raise SessionInterruptedError (f"Editing session { editing_id } was interrupted" )
161161
162162 if isinstance (message , AssistantMessage ):
163163 for block in message .content :
You can’t perform that action at this time.
0 commit comments