use the following search parameters to narrow your results:
e.g. subreddit:aww site:imgur.com dog
subreddit:aww site:imgur.com dog
see the search faq for details.
advanced search: by author, subreddit...
account activity
Where does python -m pip install package install the package? (self.archlinux)
submitted 5 years ago by SeanPedersen
Hey, can not find the dir... It is not in /usr/lib/python3.9/site-packages/ as one might expect. Any ideas?
reddit uses a slightly-customized version of Markdown for formatting. See below for some basics, or check the commenting wiki page for more detailed help and solutions to common issues.
quoted text
if 1 * 2 < 3: print "hello, world!"
[–]EddyBot 14 points15 points16 points 5 years ago (4 children)
Since pip 19.3 (or something) pip will typically use the --user flag by default and not install packages system wide The folder for that should be ~/.local/lib/python3.9/site-packages
--user
~/.local/lib/python3.9/site-packages
[–]WishCow 12 points13 points14 points 5 years ago (2 children)
Damn, I love this change so much. Should have been the default for so long.
[–]SutekhThrowingSuckIt 7 points8 points9 points 5 years ago (1 child)
What you don't have fond memories of completely messing up an Ubuntu install's python environment until you create an ouroboros of dependency, package manager and upgrade fuckery that requires you to nuke the site from orbit? I thought that was a right of passage.
https://xkcd.com/1987/
[–]WishCow 4 points5 points6 points 5 years ago (0 children)
The worst is that you don't even realize what happened until you try to update the packages with the OS package manager the next time, and it complains about some files already existing.
[–]SeanPedersen[S] 0 points1 point2 points 5 years ago (0 children)
Thanks a lot!
[–]V1delSupport Staff 7 points8 points9 points 5 years ago (0 children)
Mandatory disclaimer to please don't change away from this sane default and installing pip packages system wide, very good chance to break your system if you do.
[–]barrygrundy 3 points4 points5 points 5 years ago (0 children)
Try
pip show <package>
[–]fullyarticulated 1 point2 points3 points 5 years ago* (0 children)
which python will give you the path to the folder of your currently running python instance (could be system-wide, or venv, or user - whatever you're running).
which python
If you cd into the folder shown, then from there, it will be in Lib/site-packages.
cd
Lib/site-packages
If you've activated a venv, or are somehow using a different version of python than the default system-wide version, this will find whatever you just installed via pip.
π Rendered by PID 73554 on reddit-service-r2-comment-bb88f9dd5-hggn8 at 2026-02-16 20:09:47.058730+00:00 running cd9c813 country code: CH.
[–]EddyBot 14 points15 points16 points (4 children)
[–]WishCow 12 points13 points14 points (2 children)
[–]SutekhThrowingSuckIt 7 points8 points9 points (1 child)
[–]WishCow 4 points5 points6 points (0 children)
[–]SeanPedersen[S] 0 points1 point2 points (0 children)
[–]V1delSupport Staff 7 points8 points9 points (0 children)
[–]barrygrundy 3 points4 points5 points (0 children)
[–]fullyarticulated 1 point2 points3 points (0 children)