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

bpo-31009: Fix support.fd_count() on Windows #2862

Merged
merged 2 commits into from
Jul 25, 2017
Merged

bpo-31009: Fix support.fd_count() on Windows #2862

merged 2 commits into from
Jul 25, 2017

Conversation

vstinner
Copy link
Member

@vstinner vstinner commented Jul 25, 2017

On Windows, test.support.fd_count() now calls
msvcrt.CrtSetReportMode() to not kill the process nor log any error
on stderr on os.dup(fd) if the file descriptor is invalid.

https://bugs.python.org/issue31009

@vstinner
Copy link
Member Author

I tested manually: test_child_fd_inflation() of test_multiprocessing_spawn doesn't hang anymore on a debug build on Windows. Moreover, test_regrtest still pass.

" continuous-integration/appveyor/pr — AppVeyor was unable to build non-mergeable pull request" I don't understand this error :-( My commit is just on top on master. I updated my local Git clone, there is no new commt in master.

@vstinner
Copy link
Member Author

I ran manually the test suite on Windows: all tests pass. To be honest, test_distutils fails, but it's unrelated to this change and I don't know how to fix my Windows support to get a working C compiler...

@vstinner
Copy link
Member Author

"AppVeyor was unable to build non-mergeable pull request" : "To rebuild that PR you can close and then re-open it."
http://help.appveyor.com/discussions/problems/4830-stuck-on-appveyor-was-unable-to-build-non-mergeable

@vstinner vstinner closed this Jul 25, 2017
@vstinner vstinner reopened this Jul 25, 2017
On Windows, test.support.fd_count() now calls
msvcrt.CrtSetReportMode() to not kill the process nor log any error
on stderr on os.dup(fd) if the file descriptor is invalid.
@vstinner
Copy link
Member Author

Crap, there was a whitespace issue... "Fixing Python file whitespace ... 1 file: Lib/test/support/init.py". It's now fixed.

@vstinner
Copy link
Member Author

Travis CI failed on downloading Python 3.6 on the docs job :-(

Downloading archive: https://s3.amazonaws.com/travis-python-archives/binaries/ubuntu/14.04/x86_64/3.6-python.tar.bz2
$ sudo tar xjf python-3.6.tar.bz2 --directory /
bzip2: (stdin) is not a bzip2 file.

@vstinner vstinner merged commit 302bbbe into python:master Jul 25, 2017
@vstinner vstinner deleted the fd_count_win branch July 25, 2017 15:45
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants