Skip to content

Commit

Permalink
Wait for Pipelines to complete before allowing their jobs to be deleted
Browse files Browse the repository at this point in the history
  • Loading branch information
dwnusbaum committed Sep 26, 2024
1 parent 435bb79 commit 9eab23f
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion core/src/main/java/jenkins/model/queue/ItemDeletion.java
Original file line number Diff line number Diff line change
Expand Up @@ -266,7 +266,7 @@ public static void cancelBuildsInProgress(@NonNull Item initiatingItem) throws F
// comparison with executor.getCurrentExecutable() == executable currently should always be
// true as we no longer recycle Executors, but safer to future-proof in case we ever
// revisit recycling.
if (!entry.getKey().isAlive()
if (!entry.getKey().isActive()
|| entry.getValue() != entry.getKey().getCurrentExecutable()) {
iterator.remove();
}
Expand Down

0 comments on commit 9eab23f

Please sign in to comment.