Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Improve handling of SIGINT. #10046

Merged
merged 2 commits into from Dec 18, 2020
Merged

Improve handling of SIGINT. #10046

merged 2 commits into from Dec 18, 2020

Conversation

reitermarkus
Copy link
Member

  • Have you followed the guidelines in our Contributing document?
  • Have you checked to ensure there aren't other open Pull Requests for the same change?
  • Have you added an explanation of what your changes do and why you'd like us to include them?
  • Have you written new tests for your changes? Here's an example.
  • Have you successfully run brew style with your changes locally?
  • Have you successfully run brew typecheck with your changes locally?
  • Have you successfully run brew tests with your changes locally?
  • Have you successfully run brew man locally and committed any changes?

  1. Make ignore_interrupts raise an Interrupt exception afterwards if there was an an attempt to interrupt it.

    If I press CTRL-C, I expect brew to exit after the “One sec, cleaning up...” message and not continue running until I happen to find a “correct” position where pressing CTRL-C actually works.

  2. Change SystemCommand to spawn processes in another process group, so that the parent process can send SIGINT to the child rather than the child receiving it directly. We want to raise an Interrupt exception rather than the child exiting with a Process::Status containing only a signal but no actual exit status.

@BrewTestBot
Copy link
Member

Review period will end on 2020-12-18 at 16:11:03 UTC.

@BrewTestBot BrewTestBot added the waiting for feedback Merging is blocked until sufficient time has passed for review label Dec 17, 2020
@BrewTestBot
Copy link
Member

Review period ended.

@BrewTestBot BrewTestBot removed the waiting for feedback Merging is blocked until sufficient time has passed for review label Dec 18, 2020
@reitermarkus reitermarkus merged commit 89e5d80 into Homebrew:master Dec 18, 2020
@reitermarkus reitermarkus deleted the sigint branch December 18, 2020 16:44
@BrewTestBot BrewTestBot added the outdated PR was locked due to age label Jan 18, 2021
@Homebrew Homebrew locked as resolved and limited conversation to collaborators Jan 18, 2021
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
outdated PR was locked due to age
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants