T
Termux•3mo ago
beskwho

Installing pip is forbidden

Hey. Pip has been broken for me for many months. I'm at a point where it needs to be fixed. So I'll post my problem. Attempting to update pip (python3 -m pip install --upgrade pip) gives this message: ERROR: Installing pip is forbidden, this will break the python-pip package (termux). I'm not sure how to remedy this. Please help.
No description
27 Replies
ted
ted•3mo ago
@beskwho what problem are you trying to solve? in what way is pip "broken"? (the message is correct in any case - if that succeeded, it would break pip. but there isn't enough info here to tell if a pip upgrade would even help.)
TomIO
TomIO•3mo ago
Python on Termux follows PEP668. https://peps.python.org/pep-0668/ Our python-pip package requires patches and non-standard build options to function. Which the pip self update is not able to apply. https://github.com/termux/termux-packages/tree/master/packages/python-pip
Python Enhancement Proposals (PEPs)
PEP 668 – Marking Python base environments as “externally manag...
A long-standing practical problem for Python users has been conflicts between OS package managers and Python-specific package management tools like pip. These conflicts include both Python-level API incompatibilities and conflicts over file ownership.
GitHub
termux-packages/packages/python-pip at master · termux/termux-pack...
A package build system for Termux. Contribute to termux/termux-packages development by creating an account on GitHub.
beskwho
beskwhoOP•3mo ago
How would I know? You know all I know. The message claims installing pip is forbidden. Okay, so how do I go about updating pip without breaking anything?
ted
ted•3mo ago
@beskwho I don't think you understood my question. in the original message, you said "Pip has been broken for me for many months". "broken" can mean a million different things, so I asked for the exact error you're getting and what you do to cause it. explained why, too
beskwho
beskwhoOP•3mo ago
Hey @ted , please read the full support text before responding. There's no need to get toxic. The error message states installing pip will break the package. Since I received the error, updating pip has not functioned. Installing new Python scripts through pip results in hangups.
ted
ted•3mo ago
pretty low bar for toxic there but whatever as both Tom and I said, it is intentional and necessary that the pip provided by termux is patched to prevent installing or upgrading pip via pip from working, so the mesage in the screenshot is not a surprise to us and there is no fix or workaround your original message says "pip has been broken for me for many months" and then "attempting to update pip gives this message", which I interpreted as "I am having a problem with pip and am trying to fix it by upgrading pip", with the original problem not specified that's the question I've asked you twice now I think I'm getting that the original problem was that upgrading pip with pip doesn't work so now that you know that it's intentional and necessary that this does not work why do you want to upgrade pip, @beskwho
Installing new Python scripts through pip results in hangups.
exact command ~would be helpful~ is necessary here as well first thing I'll want to do is try to reproduce your issue on my own device, and I currently can't try, because I don't know what I'm reproducing
beskwho
beskwhoOP•3mo ago
Occasionally I want to install Python scripts. Lately I've wanted to install wordcloud. Which seems to be available only through pip. But when I attempt to install it, the installation process hangs. Which I assume is because pip is currently not functional, because it hasn't been updated in ages, because it's fucked. So I'm attempting to fix pip whatever it takes. If it means removing it and reinstalling, whatever, I'm not a techie. Also not sure who Tom is.
ted
ted•3mo ago
Tom is this person
beskwho
beskwhoOP•3mo ago
python3 -m pip install --upgrade pip
ted
ted•3mo ago
Which I assume is because pip is currently not functional, because it hasn't been updated in ages, because it's fucked.
so you now know this assumption is wrong, because you have two people telling you so python3 -m pip install --upgrade pip should not and cannot work so your actual problem is that, for example, python3 -m pip install wordcloud hangs? I need the exact command, and to know exactly what (if any) output you're getting before it hangs @beskwho ping because I can try reproducing the problem once I know those things
beskwho
beskwhoOP•3mo ago
The process locks here at the 'Installing backend dependencies' stage.
No description
beskwho
beskwhoOP•3mo ago
It's the same with other pip installations.
ted
ted•3mo ago
so that / should be spinning, I think I'm assuming when you say it hangs, you mean it stops spinning, and not that it keeps spinning but doesn't progress past that line?
beskwho
beskwhoOP•3mo ago
Correct, the little symbol stops spinning and the installing doesn't progress further. It just stalls.
ted
ted•3mo ago
how long have you waited, at the longest? (I've got exactly what you're describing on my screen now) well, now my / is a -
beskwho
beskwhoOP•3mo ago
I had it running for an hour the previous attempt. I'm fairly confident it has just stopped and the installation failed.
ted
ted•3mo ago
have you had problems with any other modules? so far this looks like an issue with wordcloud
beskwho
beskwhoOP•3mo ago
I believe I tried installing matplotlib also to the same effect.
ted
ted•3mo ago
it's doing a lot of work installing things from source, via pypi, that you should just get as binaries from termux repos so I'm working through adding those and it's making progress pkg up, and then you'll need a few more things so far I have cmake ninja patchelf python-numpy python-pillow qhull okay, only took a few seconds after that @beskwho pkg up pkg i cmake ninja patchelf python-numpy python-pillow qhull pip install wordcloud nothing wrong with anything, just a really big dependency tree with some big programs/libs in it (and a couple that need patches for termux)
Catinette
Catinette•3mo ago
I don't understand one thing why would people try to install pip via pip or python -m pip when the error actually gives them the actual package you have to update? python-pip so in the end, nothing was broken
ted
ted•3mo ago
there is no pip update available via termux repos, so if you believe you need to update pip, you believe you still have a problem but yes, I see no breakage here, just a package with a lot of dependencies
Catinette
Catinette•3mo ago
okay
beskwho
beskwhoOP•3mo ago
I allowed the wordcloud installation to run for an hour and it finally ended with the longest error message in history.
No description
Catinette
Catinette•3mo ago
cmake is available in termux repos
ted
ted•3mo ago
@beskwho did you do what I said here? you never responded to it I suspect you didn't, if you're getting any output related to building cmake - please read the messages above that as well
beskwho
beskwhoOP•3mo ago
@TEDDY 🧸 Alright to be honest, I skimmed through your post because the wall of text was daunting. But yeah, I did try your suggestions and hey presto, problem solved. @ted Oops this one
ted
ted•3mo ago
glad it worked

Did you find this page helpful?