gh-72660: Handle unsigned long win32 error codes by ameily · Pull Request #27959 · python/cpython (original) (raw)
The failed tests look like winerror_to_errno
isn't handling error code with the top bit set properly, but I suspect it's due to the conversions we've added.
I'm also a little concerned about changing values in OSError.winerror
for users. Not sure whether our tests cover that, but that seems like an annoying change that I'd rather not make.1
Footnotes
- Won't affect my own code, because I always
ex.winerror & 0xFFFFFFFF
before comparing, but I don't believe that's a universal pattern. ↩