-
-
Notifications
You must be signed in to change notification settings - Fork 10.9k
build breaks with new virtualenv 1.8.3 on py3 #2761
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
Comments
Here's the distribute followup: https://bitbucket.org/tarek/distribute/issue/334/ Paging @teoliphant and @pearu who may explain that part of the code. |
This is not a numpy issue but a Python bug. Caused by:
Same issue at statsmodels/statsmodels#204 and luispedro/mahotas#25. Comment from statsmodels issue: The use of |
@stefanholek FYI |
detach seems like the right thing to do for distribute's requirement of having stdout in the right encoding. I was wondering if numpy had a particular need to communicate. Why does numpy code use |
Oh, to clarify: there's no bug in the way detach is used by distribute. sys.stdout is reassigned atomically. Quick demo:
|
hmm, I don't know about that. I believe the offending line in distribute's dist.py is: sys.stdout = io.TextIOWrapper(sys.stdout.detach(), 'utf-8',
errors, newline, line_buffering) python is strict and the constructor is called prior to the assignment. |
Sure, but the "detach() is broken" line of thought is still a red herring in this discussion. It's not what's happening here. |
comment removed, my bad |
@g2p you're right that like that the detach call does not raise an error. This code in numpy is almost 10 years old, written to support Python 2.1. Trying to find out what problem was being worked around at that time will be a painful and not very useful way to spend ones time. Anyway this code is present in many released numpy versions; many other packages depend on numpy.distutils. The only reasonable solution I can see is to undo the distribute commit. |
Or fix it by also replacing |
Summary so far (as I understand it):
|
Good summary. About 8), it's not only related to Travis, but anyone who installs distribute 0.6.30 won't be able to install things that rely on numpy.distutils I think. |
Updated, thank you. |
Does anyone have a good workaround for Travis? |
For future reference: fixed in master branch by 649c908 |
I've opened a coressponding issue in venv: pypa/virtualenv#359.
If the numpy team could lend a hand in debugging this, that'd be great.
The text was updated successfully, but these errors were encountered: