Problem with pip vs pacman

If I use the pacman installed versions of pyqtwebengine / pyqt5 / sip, then my installation of emacs-eaf does not work.

If I use pip installed versions, it does work, but then as soon as something updates or needs pacman versions of these packages it doesn’t.

e.g. I installed calibre and got a load of python packages, that overwrote my pip installations :frowning:

I got around it with installing the repo versions and the force installing the pip versions:

sudo pip install pyqtwebengine --force

But obviously this is a bit precarious, I am going to add them to IgnorePkg, but wondered if there was a better way?

BTW eaf is emacs application framework, so I can open a browser in emacs:

image

Do not use sudo with pip. If you need python packages installed globally use pacman or yay.

2 Likes

Using sudo pip on any Arch based distro is going to be a nightmare.

I am not familiar with emacs-eaf but typically you would use pip without sudo to install those components to your home directory and then have the application use those.

3 Likes

Have too, emacs does not see a user installation of the packages, tried it. Sudo is the only way to get it running.

What did you try to make emacs use your local python path?

There is no option for emacs to see a user vs a root, it looks only in the /usr/lib/python3.8/site-packages directory. Been using this for close to a year, it has always been fiddly.

kinda off topic but I have a question about pip; how do you unisntall programs insatlled with pip?

pip uninstall packagename

https://pip.pypa.io/en/stable/user_guide/#uninstalling-packages

If you installed them with sudo pip you need to use sudo pip to remove them.

tried that - it was the first I thought of - but no it didn’t work

I don’t remember everything now - but I read a lot about it to figure it out and there was some commands with options but those didn’t work either

Can you give us a little more background here? How did you install them in the first place? What pip command did you run specifically and what error did you receive?

sorry my bad it wasn’t pip it was npm

I just checked the package and it was npm

1 Like