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

On travis: ImportError: No module named download #23

Closed
robnagler opened this issue Apr 24, 2018 · 4 comments
Closed

On travis: ImportError: No module named download #23

robnagler opened this issue Apr 24, 2018 · 4 comments

Comments

@robnagler
Copy link
Member

If you look at the previous build, it's got the same version of pip, but it doesn't get this error:

$ python --version
Python 2.7.14
$ pip --version
pip 9.0.1 from /home/travis/virtualenv/python2.7.14/lib/python2.7/site-packages (python 2.7)
install.1
$ pip install setuptools==32.1.3
$ python setup.py pkdeploy
Traceback (most recent call last):
  File "setup.py", line 7, in <module>
    from pykern.pksetup import setup
  File "/home/travis/build/radiasoft/pykern/pykern/pksetup.py", line 51, in <module>
    import pip.download
ImportError: No module named download
@slacAWallace
Copy link

I had a very similar issue, which prevented installation of sirepo.

Traceback (most recent call last): File "setup.py", line 7, in <module> from pykern.pksetup import setup File "/home/vagrant/src/radiasoft/codes/pykern-20180517.171435/pykern/pykern/pksetup.py", line 51, in <module> import pip.download ImportError: No module named download 2018-05-17T17:14:30Z install_main Unexpected error; Install failed.

@robnagler
Copy link
Member Author

Looks like the moved pip.download to pip._internal.download. From the Release Notes:

Move all of pip's APIs into the pip._internal package, properly reflecting the fact that pip does not currently have any public APIs. (#4696, #4700)

We use pip to parse requirements.txt so we'll change that to whatever is recommended.

robnagler pushed a commit that referenced this issue May 19, 2018
pip removed all APIs in version 10 so pip.download and pip.main are not allowed.
It's impractical to support pykern being installed automatically so packages
will have to install pykern before they run setup.py if they refer to
pykern in setup.py (e.g. using pksetup). For RadiaSoft, this isn't a
problem, because we install from known environments setup by our curl
installers (usually inside vagrant or docker). For others, it's a design
flaw that you can't use a library in setup.py that is not in base python.
To get projex_test.py to work with tox, added some code inside pksetup.py
that supports looking for the right python version.
Removed extras_require, because I don't think that's necessary any more
to build jupyterhub.
@robnagler
Copy link
Member Author

@slacAWallace Please try the last step again. Thanks.

robnagler pushed a commit to radiasoft/rshellweg that referenced this issue May 19, 2018
robnagler pushed a commit to radiasoft/rshellweg that referenced this issue May 19, 2018
robnagler pushed a commit to radiasoft/rsconf that referenced this issue May 19, 2018
robnagler pushed a commit to radiasoft/rszgoubi that referenced this issue May 19, 2018
robnagler pushed a commit to radiasoft/rshellweg that referenced this issue May 19, 2018
@slacAWallace
Copy link

slacAWallace commented May 21, 2018

Yes that seemed to do the trick. Install was successful. Thanks!

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

No branches or pull requests

2 participants