Allow to disable warning for root user package management#10990
Allow to disable warning for root user package management#10990
Conversation
c16a7f7 to
cb16e02
Compare
1644193 to
f536c1f
Compare
pradyunsg
left a comment
There was a problem hiding this comment.
Thanks for picking this up! ^.^
I have a few suggestions for changes throughout this PR, mostly around being consistent with the rest of the implementation for how we handle options.
I would request you to drop the reference to the issue from the commit message, since that causes excessive spam in the original GitHub issue, with an event every time you make a force-push.
Since you'll likely be editing the commit message, as a nit-pick, it would be good for it to not reference specific URLs and to not state "this PR" (it's associated with commit, which can be used independently of a PR).
Implements the flag that allows to disable the root warning when using `pip` to install packages. While there are differing opinions on this, it seems that the final decision is to lean forward to implement a long and not very easily discoverable flag to accommodate the minority of users who know what they are doing and using root installation to - for example build optimized Dockerfiles.
e3224b3 to
62b2264
Compare
|
I believe all comments applied. Thanks for fast review! |
Given that this option is on the install/uninstall commands, it is implied that the warning is presented as part of an installation/uninstallation.
|
Cool! thanks! |
|
Does this also mean that we can define |
|
I think it needs to be |


This PR implements the flag that allows to disable the root
warning when using
pipto install packages. While there arediffering opinions on this, it seems that the final decision is
to lean forward to implement a long and not very easily
discoverable flag to accommodate the minority of users who know
what they are doing and using root installation to - for example
build optimized Dockerfiles.
Even approval, and eventually an adoption of PEP 668 to make the
problem largely go away is still a long time to go, so as
discussed in #10556 (comment)
this PR adds a long and non-user friendly flag to handle the
situation.
Fixes: #10556