-
-
Notifications
You must be signed in to change notification settings - Fork 1.2k
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
ImportError during pip build with Setuptools 34 and pip 6.0 #945
Comments
As a workaround, try |
@mgedmin - where would I put that in a .travis.yml? What's the real fix here? |
I took a stab in python-excel/xlrd#194 and it seems to be a suitable workaround. The issue lies with pip and I've detailed the problem and proposed solution in pypa/pip#4253. |
@jaraco - if this is a pip issue, why did a setuptools release cause it? Would be great if you could do a setuptools release to revert until there's a real fix rather than requiring everyone-who-does-nightly-builds to go and change their CI scripts... |
Well, it was an unanticipated issue, and I didn't encounter it during my testing. Indeed, no one identified any issues in the two beta releases I made. This change was released as a backward-incompatible release knowing that it might have some issues. In fact, it's only affecting a small number of projects that happen to be updating setuptools as part of another pip upgrade operation. Since the impact is fairly small and the workaround simple enough, it's not worth the cost and effort of backing out these changes and rolling them out at another time. |
I believe this is affecting ALL of my projects that use Python 2 on Travis CI. |
@jacebrowning: Can you share an example? Is the issue identical? In the aforementioned xlrd workaround, I've suggested perhaps developing a script to run across the affected projects and apply a workaround. Surely the presence of your additional use-cases is pertinent and an indicator of a more widespread issue. |
@jaraco This build passed a few days ago, but failed on rebuild: https://travis-ci.org/jacebrowning/verchew/jobs/190372989 docopt fails to install setuptools?
|
By digging into that project, I see that it effectively invokes |
Annoyingly, I've been unable to replicate the issue. Even if I use Python 2.7 and download the requirements.txt from xlrd, they install fine. I can't get setuptools to build/install before its dependencies. I see on the failing test that it's using pip 6.0.7. Perhaps that's a factor also. |
I was able to replicate the issue by pinning to pip 6.0.7 and running this script:
|
Bisecting, it seems the issue goes away between pip 6.0.8 and pip 6.1. |
The issue was fixed in pypa/pip#2478 released April 2015. Given that the issue is isolated only to old versions of pip and is triggered by aggressive upgrading of packages, I'm going to say that this has to be a won't fix, as I don't think there's a reasonable way to support an arbitrary mix of old and new packages... and since the final fix is already in place in pip, the best recommendation will be to upgrade pip. |
@cjw296, @jacebrowning I unfortunately don't see a solution for this issue in Setuptools. I could backout the changes for the v34 release, but then at what point could those be introduced? It appears the only option we have is to recommend that the projects (or CI environments perhaps) either update pip or don't upgrade setuptools. Can you think of any other options? |
Or upgrade both ( |
Workaround for pypa/setuptools#945
Workaround for pypa/setuptools#945
Interestingly, this only appears to be affecting some of my projects, notably ones that use requirements.txt but also a couple that don't. Very strange. Anyway, since it seems like there's no choice but to insert the hack, I'll do that and see what happens. |
Until pypa/setuptools#945 closes, we are tagging setuptools to latest known working version. Change-Id: I4d6a04fac12afcceacd33fcea2c4d009f8e62c2c
Here's a build where the hack recommended doesn't work: https://travis-ci.org/Simplistix/picky/jobs/196432515 Here's the CI file: |
This is part of the traceback:
This started when 34.0.2 was released, here are some examples of the nightlies it's causing the fail:
https://travis-ci.org/python-excel/xlrd
https://travis-ci.org/Mortar/mortar_import
The text was updated successfully, but these errors were encountered: