File tree Expand file tree Collapse file tree 1 file changed +14
-0
lines changed
internal-packages/run-engine/src/engine/systems Expand file tree Collapse file tree 1 file changed +14
-0
lines changed Original file line number Diff line number Diff line change @@ -99,6 +99,20 @@ export class DequeueSystem {
9999 const snapshot = await getLatestExecutionSnapshot ( prisma , runId ) ;
100100
101101 if ( ! isDequeueableExecutionStatus ( snapshot . executionStatus ) ) {
102+ // If it's pending executing it will be picked up by the stalled system if there's an issue
103+ if ( snapshot . executionStatus === "PENDING_EXECUTING" ) {
104+ this . $ . logger . error (
105+ "RunEngine.dequeueFromMasterQueue(): Run is already PENDING_EXECUTING, removing from queue" ,
106+ {
107+ runId,
108+ orgId,
109+ }
110+ ) ;
111+ // remove the run from the queue
112+ await this . $ . runQueue . acknowledgeMessage ( orgId , runId ) ;
113+ return null ;
114+ }
115+
102116 //create a failed snapshot
103117 await this . executionSnapshotSystem . createExecutionSnapshot ( prisma , {
104118 run : {
You can’t perform that action at this time.
0 commit comments