Skip to content

Commit fb56932

Browse files
committed
If a run is locked then it’s too late to expire it
1 parent f572c0f commit fb56932

File tree

1 file changed

+7
-0
lines changed
  • internal-packages/run-engine/src/engine

1 file changed

+7
-0
lines changed

internal-packages/run-engine/src/engine/index.ts

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1941,6 +1941,13 @@ export class RunEngine {
19411941
return;
19421942
}
19431943

1944+
if (run.lockedAt) {
1945+
this.logger.debug("Run cannot be expired because it's locked, so will run", {
1946+
run,
1947+
});
1948+
return;
1949+
}
1950+
19441951
const error: TaskRunError = {
19451952
type: "STRING_ERROR",
19461953
raw: `Run expired because the TTL (${run.ttl}) was reached`,

0 commit comments

Comments
 (0)