Urgh, I posted this in pypa/setuptools but it probably belongs here.
This confuses me a lot:
$ python3 -m pip install -U pip setuptools wheel cmake --user Collecting pip ... Collecting setuptools ... Collecting wheel ... Collecting cmake ... File "<string>", line 1, in <module> ModuleNotFoundError: No module named 'setuptools'
As seen on Azure CI for Ubuntu 18.04. Why can't pip figure out to install setuptools first?
As a work-around, I install this now in two steps...
cmakepackage and it does not declare its
pip install ontheflyI get this message:
Defaulting to user installation because normal site-packages is not writeable
❯ sudo onthefly sudo: onthefly: command not found
sudo, I advise you to make it re-run itself with
sudoif it doesn't have root privileges
@agronholm I googled "re-running python script with sudo" to see if I could find some an example of what you mean. I found this stackoverflow question: https://stackoverflow.com/questions/5191878/change-to-sudo-user-within-a-python-script . Is that what you mean?
Use Tcl and Expect, plus subprocess to elevate yourself. So basica ...
pip install evdevit gets installed in
/usr/local/lib/python3.6/dist-packages. Is there a way to configure this for example inside
pip install ontheflyit gets installed inside my home dir:
elevatepackage a try, which seems to be designed exactly for the use-case I'm having now.