-
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
Rework the functionality of PIP_CONFIG_FILE #11850
Rework the functionality of PIP_CONFIG_FILE #11850
Conversation
@@ -29,11 +29,15 @@ pip has 4 "levels" of configuration files: | |||
- `base` : per-base environment configuration file, shared across all virtualenvs with the same base. (available since pip 23.0) | |||
- `site`: per-environment configuration file; i.e. per-virtualenv. | |||
|
|||
Additionally, environment variables can be specified which will override any of the above. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Likely also need to mention command line arguments also override configs.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
We have this information already, in https://pip.pypa.io/en/stable/topics/configuration/#precedence-override-order
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I'm OK to move that section around, if people think that's too late in the file.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM, assuming the PR is rebased. I retitled the PR, but I don't fully know if that's the best title for this. :)
7a1cdf1
to
64448f9
Compare
pre-commit.ci autofix |
2142220
to
8879dc4
Compare
Is there anything else I need to do for this? |
8879dc4
to
87878a8
Compare
87878a8
to
08c973b
Compare
Also ensure iter_config_files behaves consistently with OVERRIDE_ORDER
for more information, see https://pre-commit.ci
207bef1
to
662246a
Compare
Thanks @dalebrydon, both for working on this and being patient & accomodating here! ^.^ |
Fixes #11815. Properly document that
PIP_CONFIG_FILE
will override all other config files. Also make a minor modification and documentation change toiter_config_files
to have the order match the override order.I also documented the fact that setting
PIP_CONFIG_FILE
prevents the user config file from being loaded. This feels like very weird behaviour to me, but has probably existed for too long to change at this point.