Join GitHub today
GitHub is home to over 40 million developers working together to host and review code, manage projects, and build software together.Sign up
Fix 500 error when using wheel_async #51321
This fixes this by only adding the signal data to the
When `wheel_async` is used, the job completes, but for the same reason we couldn't replace the signal in the first place, we fail to restore it after control is returned to the context manager. This fixes this by only adding the signal data to the `old_signals` dict when we successfully override the signal handling, so that we don't incorrectly attempt to "restore" the signal later.