I am installing Python in Termux, but I am getting this error:
pkg install python
Output:
Checking availability of current mirror: ok
Reading package lists... Done
Building dependency tree... Done
E: Unable to locate package python
I am installing Python in Termux, but I am getting this error:
pkg install python
Output:
Checking availability of current mirror: ok
Reading package lists... Done
Building dependency tree... Done
E: Unable to locate package python
I think you haven't updated the repository. It looks like you have just installed Termux. Anyway, execute
apt update
and then install any package.
The following combination of answers from this post worked for me:
termux-setup-storage
termux-change-repo
(I selected Albatros)pkg update
and pkg upgrade
exit
and then restart termuxpkg install python -y
Termux has halted all updates through Google Play. Download it from F-Droid. Then change the mirror. It works (sometimes).
termux-change-repo
Or change it manually by editing the sources.list file in directory $PREFIX/etc/apt.
Check out my blog post for more links.
Download it from F-Droid instead of Google Play.
The link is *https://f-droid.org/en/packages/com.termux/.
Make sure you have an Internet connection, and then allow access to your storage.
Run termux-setup-storage
. This should ask you for permissions to allow termux to use your device storage.
Then to confirm storage is accessible, run ls ~/storage/shared
to list directories contained in shared storage.
If this doesn't work, try switching repositories as some other answers suggest, as the node you're on may be down.
Try to upgrade your Termux via pkg upgrade
. Then it finds the packages on pkg.
Only for mobile Termux:
termux-change-repo
There might be services for game and science needed to select all the three options and select the A1batross's options, thereby completing all the permission process steps.
Once done with all these steps, you can install and do operation as a Linux terminal.
PS: update the apt would be better before any other steps
I changed my Termux repository to A1batross'.
Just give storage permissions and restart the application. It worked fine for me.
© 2022 - 2024 — McMap. All rights reserved.
f-droid
instead of google play makes sense to solve the error. Unfortunately, your answer is still top. – Leafy