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

Can unearth read from ~/.pip/pip.conf ? #13

Closed
SurenNihalani opened this issue Jul 10, 2022 · 4 comments
Closed

Can unearth read from ~/.pip/pip.conf ? #13

SurenNihalani opened this issue Jul 10, 2022 · 4 comments

Comments

@SurenNihalani
Copy link

Is your feature request related to a problem? Please describe.
I'd like unearth to implicitly pick up the internal index url from pip.conf

@Hnasar
Copy link

Hnasar commented Jul 10, 2022

This would also help our company port to PDM 2.0.

@frostming
Copy link
Owner

pip has three layers of OS-dependent configuration files and supports overriding via env vars. Ref: https://pip.pypa.io/en/stable/topics/configuration/

It is over-complicated to read such configurations which are not part of unearth itself, unless we hard depend on pip. IMO it is not worth the effort. @Hnasar PDM 2.0 has its own configurations of PyPI URLs, why would you still rely on the pip conf if you are going to port to PDM?

@Hnasar
Copy link

Hnasar commented Jul 12, 2022

@frostming at Beta we have ~50 python projects. Previously:

  1. we had all devs configure a pip.conf so that pip and pdm used our internal package registry (with netrc for listing credentials)
  2. For CI we set a environment variable for the index url

For 1: If PDM 2.0 doesn't read pip.conf then I will need to go through and add tool.pdm.source to all the pyproject.toml files.

For 2: I can easily add another CI variable for PDM's index url, but I really just want pip and PDM to always use the same url.

So this change is a small hassle for users with many repos. I wish pep 621 had a standard configuration for the index url.

@sleiner
Copy link
Contributor

sleiner commented Jul 24, 2022

If PDM 2.0 doesn't read pip.conf then I will need to go through and add tool.pdm.source to all the pyproject.toml files.

@Hnasar You can configure your PyPI mirror in pdm.conf and it will be used by all projects - wouldn't that solve your problem?

@SurenNihalani SurenNihalani closed this as not planned Won't fix, can't repro, duplicate, stale Nov 8, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

4 participants