Is it possible to have different Python indexes fo...
# general
m
Is it possible to have different Python indexes for different resolves?
h
It is not today, no. This could be implemented though, if there was enough demand.
b
• Theres private support for this in 2.18 for internal reasons. That could be flexed to be external • You can generate lockfiles yourself (which we do) which provides ultimate flexibility
h
You mean not use Pants to generate lockfiles? How would that work?
b
Use
pex3 lock ...
šŸ™‚
h
And then manually add the dumb preamble header?
b
Or disable the Pants check šŸ™‚ Not advocating for it as a long-term solution, but all the pieces are there
h
Seems like we could support this a little less annoyingly... šŸ™‚
If we agree on it and if @modern-manchester-33562 is willing to do some work :)
m
Currently we solve this with an alternative pants toml like so:
PANTS_CONFIG_FILES=pants.alt.toml pants generate-lockfiles --resolve=python-alt
It works great but it is slightly inconvenient since we have to invoke two
generate-lockfiles
commands. The reason for this is due to annoying local versions (e.g.
1.2.3+blabla
). If there is an alternative to handle those that would also solve the issue for us but AFAIK pip is very persistent in picking these "plus" versions.