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

21.3: No longer looking for pip.conf in ~/Library/Application Support/pip/ #10571

Closed
1 task done
CMUboy opened this issue Oct 11, 2021 · 6 comments · Fixed by #10585
Closed
1 task done

21.3: No longer looking for pip.conf in ~/Library/Application Support/pip/ #10571

CMUboy opened this issue Oct 11, 2021 · 6 comments · Fixed by #10585
Labels
C: configuration Configuration management and loading OS: macos MacOS specific state: needs reproducer Need to reproduce issue type: bug A confirmed bug or unintended behavior
Milestone

Comments

@CMUboy
Copy link

CMUboy commented Oct 11, 2021

Description

After upgrading to pip 21.3, it no longer read the configuration file in ~/Library/Application Support/pip/.

Expected behavior

Please read the configuration file in ~/Library/Application Support/pip/.

pip version

21.3

Python version

3.8.5

OS

macOS 11.6

How to Reproduce

  1. Upgrade pip to 21.3
  2. Put configuration in ~/Library/Application Support/pip/.
  3. Observe that the configuration is not read.

Output

No response

Code of Conduct

@CMUboy CMUboy added S: needs triage Issues/PRs that need to be triaged type: bug A confirmed bug or unintended behavior labels Oct 11, 2021
@pradyunsg pradyunsg added the C: configuration Configuration management and loading label Oct 11, 2021
@pradyunsg
Copy link
Member

21.3:

env_var:
env:
global:
  /Library/Preferences/pip/pip.conf, exists: False
  /Library/Application Support/pip/pip.conf, exists: False
site:
  /Users/pradyunsg/Developer/pip/.venv/pip.conf, exists: False
user:
  /Users/pradyunsg/.pip/pip.conf, exists: False
  /Users/pradyunsg/.config/pip/pip.conf, exists: True

21.2.4:

env_var:
env:
global:
  /Library/Application Support/pip/pip.conf, exists: False
site:
  /Users/pradyunsg/Developer/pip/.venv/pip.conf, exists: False
user:
  /Users/pradyunsg/.pip/pip.conf, exists: False
  /Users/pradyunsg/.config/pip/pip.conf, exists: True

Hmm... that's not the behaviour that I see.

@pradyunsg
Copy link
Member

We explicitly have code, to ensure that we look there:

return dirval.split(os.pathsep) + ["/Library/Application Support/pip"]

@pradyunsg
Copy link
Member

What's the output of pip config debug and pip debug for you?

@uranusjr
Copy link
Member

The path difference is probably caused by different behaviour between appdirs and platformdirs? But the report confuses me even accounting for the difference; shouldn't the Application Support directory be respected even if there's now a new directory ahead of it?

@uranusjr uranusjr added this to the 21.3 milestone Oct 11, 2021
@pradyunsg pradyunsg added state: needs reproducer Need to reproduce issue S: awaiting response Waiting for a response/more information and removed S: needs triage Issues/PRs that need to be triaged labels Oct 11, 2021
@pradyunsg pradyunsg changed the title Pip 21.3 is no longer looking for pip.conf in ~/Library/Application Support/pip/ 21.3: No longer looking for pip.conf in ~/Library/Application Support/pip/ Oct 11, 2021
@pradyunsg pradyunsg added the OS: macos MacOS specific label Oct 11, 2021
@Estartu
Copy link

Estartu commented Oct 12, 2021

Here some pip confg debug outputs

pip 21.2.4

env_var:
env:
global:
  /Library/Application Support/pip/pip.conf, exists: False
site:
  /private/tmp/test/pip.conf, exists: False
user:
  /Users/estartu/.pip/pip.conf, exists: False
  /Users/estartu/Library/Application Support/pip/pip.conf, exists: True
    global.timeout: 20
    global.upgrade-strategy: eager
    list.format: columns

pip 21.3

env_var:
env:
global:
  /Library/Preferences/pip/pip.conf, exists: False
  /Library/Application Support/pip/pip.conf, exists: False
site:
  /private/tmp/test/pip.conf, exists: False
user:
  /Users/estartu/.pip/pip.conf, exists: False
  /Users/estartu/.config/pip/pip.conf, exists: False

pip 21.3 checks the unix .config dir instead of the MacOS Application Support dir

@pradyunsg
Copy link
Member

Ah fun. I'm able to reproduce this on my MacBook.

Not sure how we'd test this, but I think I can whip up a patch for thisnovdr the weekend.

@pradyunsg pradyunsg modified the milestones: 21.3, 21.3.1 Oct 14, 2021
@github-actions github-actions bot locked as resolved and limited conversation to collaborators Nov 17, 2021
@pradyunsg pradyunsg removed the S: awaiting response Waiting for a response/more information label Mar 17, 2023
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
C: configuration Configuration management and loading OS: macos MacOS specific state: needs reproducer Need to reproduce issue type: bug A confirmed bug or unintended behavior
Projects
None yet
Development

Successfully merging a pull request may close this issue.

4 participants