Skip to content

Commit 5b23645

Browse files
authored
Merge pull request #20746 from Homebrew/download-queue-rescue-interrupts
download_queue: restore `Interrupt` handling
2 parents 16f5a67 + c017c7e commit 5b23645

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

Library/Homebrew/download_queue.rb

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -156,7 +156,9 @@ def fetch
156156
end
157157

158158
sleep 0.05
159-
rescue
159+
# We want to catch all exceptions to ensure we can cancel any
160+
# running downloads and flush the TTY.
161+
rescue Exception # rubocop:disable Lint/RescueException
160162
remaining_downloads.each do |_, future|
161163
# FIXME: Implement cancellation of running downloads.
162164
end

0 commit comments

Comments
 (0)