Open bcho opened 9 years ago
I encountered this problem too.
After diving into the source code of platter
, I found the reason:
-r requirements.txt
when building, platter
will copy the requirements.txt
file into the data directory of the final distribution. See code here,requirements.txt
file in the data directory of the distribution, platter
will automatically add -r requirements.txt
option to intall it. See code hereThis may be a deliberately designed feature, but I didn't catch the intention. I even think it goes against the main purpose of platter
, which aids in creating packages that can install without compiling or downloading on servers.
After reading the pip documentation, I realized that this behavior for adding -r requirements.txt
option is correct. It's the pip's issue, not platter's.
I have opened an issue at pip, see what will happen next.
@RussellLuo A quick & dirty solution is to rewrite all vcs deps in the requirements.txt after building the wheel.
Yeah, that's an obvious solution. But I think it's more elegant to install all wheels directly like this:
$ pip install $(ls /local/wheels/*.whl)
Until pip provides a more standard solution, I'll use this one.
In my requirements.txt, I have a vcs dependency like:
Platter can build this dependency into a wheel, but during the install step, it will clone this repo again.
How can I make pip install this dependency from wheel instead of cloning from vcs?