File tree 2 files changed +20
-0
lines changed 2 files changed +20
-0
lines changed Original file line number Diff line number Diff line change @@ -74,6 +74,25 @@ $ echo "your-password" | keyring set pypi.company.com your-username
74
74
$ pip install your-package --index-url https://pypi.company.com/
75
75
```
76
76
77
+ Pip does not query ` keyring ` for credentials when ` --no-input ` is used unless
78
+ ` --keyring-does-not-prompt ` is used as well. ` keyring ` backends might not
79
+ require any user interaction at all, they might prompt for more information on
80
+ the console, or they could do things like trigger a security notification on a
81
+ mobile device which needs to be approved. That is why Pip has to be
82
+ conservative and users should be confident their configured backend requires no
83
+ user input.
84
+ Tools such as Pipx and Pipenv which either show a fancy progress indicator that
85
+ hides output from the Pip subprocess, or pass ` --no-input ` to the Pip
86
+ subprocess (or do both) are a situation where you will want to do some variant
87
+ of the following since it does not require support from the tool:
88
+
89
+ ``` bash
90
+ # possibly with --user, --global or --site
91
+ $ pip config set global.keyring-does-not-prompt true
92
+ # or
93
+ $ export PIP_KEYRING_DOES_NOT_PROMPT=1
94
+ ```
95
+
77
96
Note that ` keyring ` (the Python package) needs to be installed separately from
78
97
pip. This can create a bootstrapping issue if you need the credentials stored in
79
98
the keyring to download and install keyring.
Original file line number Diff line number Diff line change
1
+ Add ``--keyring-does-not-prompt `` flag which allows ``keyring `` lookups in combination with ``--no-input ``. See the Authentication page in the documentation for more info.
You can’t perform that action at this time.
0 commit comments