What's the problem this feature will solve?
In addition to VCS requirements which have the form of a proper URL, pip also partially supports a git specific scheme of the form [email protected]:user/repo.git. As currently documented, this scheme is supported for editable installs only.
Supporting this scheme has a number of drawbacks:
link.is_vcs
returns False
for such pseudo-URLs), and properly supporting it everywhere would be very complex.This scheme is easily replaced by URLs such as
Describe the solution you'd like
Deprecate support for this format during one year, then remove it (#7543).
Alternative solutions
This was released in 20.0, so 21.0 should remove this feature.
It is not possible to make a relative path with the URL syntax. This artificially limit the power of pip for no reason. git+…
simply passes …
to git clone …
. For example, if I have a branch that I want to install as a dependency:
pip install -e git+./@mydep#egg=mydep
This _WILL_ break existing software and there will be no fix.
Never mind, I found a workaround using the environment variable support in requirements.txt
:
-e git+file://${PWD}@mydep#egg=mydep
@lericson interesting trick you found there.
Out of curiosity is this a real example using the current directory, and why can't you use -e .
?
The idea is to bundle slightly modified dependencies as branches in Git, then let pip install them. I'm still trying to find out how well it works though.
Apart from needing a bit of an incantation to make the dependency remote refs into local refs, it works pretty good!
@lericson good to hear! Note that if you don't specifically need an editable install, you could also use the PEP 508 notation: mydep @ git+file://${PWD}@branch
.
It actually works pretty well. The advantage of having an editable install is that it’s, well, editable. I do a fair amount of hacking on my dependencies if they’re not very mature projects. This fits that pattern well without complicating things for my users (and myself as a developer)
On 14 Aug 2020, at 19:06, Stéphane Bidoul notifications@github.com wrote:

@lericson good to hear! Note that if you don't specifically need an editable install, you could also use the PEP 508 notation: mydep @ git+file://${PWD}@branch.—
You are receiving this because you were mentioned.
Reply to this email directly, view it on GitHub, or unsubscribe.
Be careful that PWD
is not available on Windows, so you may need to jump through some hoops if you need to support that sometime.
Eh, I gave up on Windows compatibility a long time ago :-)
Most helpful comment
Eh, I gave up on Windows compatibility a long time ago :-)