bpo-23325: Turn signal.SIG_DFL and signal.SIG_IGN into functions.#8920
bpo-23325: Turn signal.SIG_DFL and signal.SIG_IGN into functions.#8920serhiy-storchaka wants to merge 3 commits into
Conversation
These singletons are no longer integers. They are now copyable and pickleable and have docstrings.
|
Why should SIG_IGN raise an error when called instead of doing nothing, which is what happens when SIG_IGN is actually supplied as a signal handler? |
Because currently calling |
|
Hmm, the problem is this will break code such as: handler = signal.getsignal(signum)
if callable(handler):
# Do something, e.g. call the handler |
iritkatriel
left a comment
There was a problem hiding this comment.
This has merge conflicts now.
|
When you're done making the requested changes, leave the comment: |
|
Victor closed the issue, so I'll close the PR too. |
These singletons are no longer integers.
They are now copyable and pickleable and have docstrings.
https://bugs.python.org/issue23325