gh-90872: Handle negative timeouts for wait on Windows#32079
gh-90872: Handle negative timeouts for wait on Windows#32079jkloth wants to merge 2 commits intopython:mainfrom
Conversation
|
Did you want to create an issue to fix |
|
I was thinking to the DWORD converter change as a separate PR that would not be a candidate for backport. While The change of negative values to exceptions, while probably not relied upon, would be a breaking change for a dot release. Being limited to a new release (3.11) would be easier to reason about downstream rather than a "random" bugfix release (say, 3.9.12). IMO. |
|
Please add tests and a NEWS entry. |
serhiy-storchaka
left a comment
There was a problem hiding this comment.
How difficult is to write tests?
Tests can spawn a child process that exits after a few seconds. With this PR, a timeout that's larger than 4294967.295 should raise |
|
The issue has been closed, is there anything left to do here? |
Update Windows wait timeout handling to match the behavior for POSIX. This PR also catches overly values that would conflict with the INFINITE timeout value used in
_winapi.WaitForSingleObject.These changes should be backported to the maintenance branches.
https://bugs.python.org/issue46716