-
Notifications
You must be signed in to change notification settings - Fork 3k
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
Pip saves vcs-dependency in zip-file with version #2835
Comments
Can you verify that this is still happening in 7.0.1? |
Hi, Donald. It seems, that behavour in 7.0.1 is the same. These are some steps for reproduce. Correct me if i'm doing something wrong.
installing (downloading actually) from branch
Let's check what was downloaded in
(i added comment in Now we try to install package using version, telling pip we want it from cache
And let us check what was installed
So package was installed from It may seem quite complex workflow for installing, but i didn't come to it by myself, we use wrapper for this called https://github.com/paylogic/pip-accel, so it does this caching work while building our project virtualenvs, but it looks that it uses pip correctly in this case. |
Oh, wait I see. It's using |
So when installing pip just checkouts repository and then it treats it like local package and installs it like other packages pointed by filesystem path, am i understanding correct? And when using download it checkouts and makes sdist and puts it in cache, so vcs repo kinda not considered? |
Noticed, that pip in 6 and 7 (maybe earlier) began to save cached vcs dependencies in zip files with version name.
So let's assume i have package
mylib
, in setup.py it has version 1.0 and i use it in my project like thisOnce i made some branch with some features in mylib, so now i wanna test it within my project from branch, so i put
in my projects
requirements.txt
in some staging branch of my project.After that i build my virtualenv like that (with files cache):
So pip says
And when i do same command in master of my project (where i have
mylib==1.0
) on same machine i got this zip file from cache, but it's not 1.0 at all, it is some fork of 1.0 version of lib with some changes made in branch.I guess, pip should save file in cache with name like
/tmp/.pip/mylib-e3e3e6fd5716577e8a31c2223d16a6e175a8bfad.zip
to avoid such problems.Any suggestions, workarounds are welcome?
The text was updated successfully, but these errors were encountered: