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

rez-pip issues finding pip executable #826

Closed
nerdvegas opened this issue Dec 17, 2019 · 0 comments · Fixed by #878
Closed

rez-pip issues finding pip executable #826

nerdvegas opened this issue Dec 17, 2019 · 0 comments · Fixed by #878
Labels
rez-pip ingesting py pkgs into rez (pip, wheels, etc)

Comments

@nerdvegas
Copy link
Contributor

Two related issues:

1

If I have a python package that provides a 'python' exe but not (eg)
python2', rez can end up using the wrong py exe:

15:22:51 INFO     Found pip-8.1.1 inside /home/ajohns/packages/python/2.7.12/package.py. Will use it with /usr/bin/python2

2

rez-pip finds pip in the following order (from docstring):
1. Search for rezified python matching python version request;
2. If found, test if pip is present;
3. If pip is present, use it;
4. If not present, search for rezified pip (this is for backwards compatibility);
5. If rezified pip is found, use it;
6. If not, fall back to rez's python installation.

However, if pip is found, but its version is <19, then rather than continue on with the search for a valid pip, it errors out with:

rez.exceptions.RezSystemError: pip >= 19 is required! Please update your pip.

I have a case where the rez installation itself has a valid pip, but rez-pip will not work because it's found a rezified pip that is <v19.

TODO

  • Check for both python and python2 available from the context (if pip is being used from a context), rather than assuming that 'python2' will be supplied (on non-windows). It would probably be enough to check that the exe is within the python/pip rez package's root. Given this change, I am not sure we would require checking for Windows anymore.
  • Continue in the search order if a <v19 pip is found
  • Improve logging to explain steps being taken.
@nerdvegas nerdvegas added the rez-pip ingesting py pkgs into rez (pip, wheels, etc) label Dec 17, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
rez-pip ingesting py pkgs into rez (pip, wheels, etc)
Projects
None yet
Development

Successfully merging a pull request may close this issue.

1 participant