termux / termux-api

Termux add-on app which exposes device functionality as API to command line programs.
https://f-droid.org/en/packages/com.termux.api/
2.34k stars 459 forks source link

termux api commands hang on Android 14 #640

Closed mogenson closed 11 months ago

mogenson commented 11 months ago

Similar to #638 The termux-api commands are broken on Android 14. The symptom is that all commands hang indefinitely. Eg termux-battery-service hangs until aborted with ctrl-c.

Termux API app is version 0.51, termux-am package is version 0.6, and termux-tools is version 1.39.5. Device is not rooted. com.termux.api app does not appear in the list of frozen cached apps.

Here's the output of termux-info:

Termux Variables:
TERMUX_API_VERSION=0.50.1
TERMUX_APK_RELEASE=GITHUB
TERMUX_APP_PACKAGE_MANAGER=apt
TERMUX_APP_PID=6892
TERMUX_IS_DEBUGGABLE_BUILD=1
TERMUX_MAIN_PACKAGE_FORMAT=debian
TERMUX_VERSION=0.118.0
Packages CPU architecture:
aarch64
Subscribed repositories:
# sources.list
deb https://mirror.quantum5.ca/termux/termux-main stable main
# tur-repo (sources.list.d/tur.list)
deb https://tur.kcubeterm.com tur-packages tur tur-on-device tur-continuous
Updatable packages:
All packages up to date
termux-tools version:
1.39.5
Android version:
14
Kernel build information:
Linux localhost 5.10.177-android13-4-00003-ga7208022a7ea-ab10815828 #1 SMP PREEMPT Fri Sep 15 16:40:54 UTC 2023 aarch64 Android
Device manufacturer:
Google
Device model:
Pixel Fold
LD Variables:
LD_LIBRARY_PATH=
LD_PRELOAD=/data/data/com.termux/files/usr/lib/libtermux-exec.so
Installed termux plugins:
com.termux.widget versionCode:13
com.termux.api versionCode:51
mogenson commented 11 months ago

Note that the termux-api commands did work on this device before the update to Android 14.

mogenson commented 11 months ago

Note, termux-api commands do work with a newer build of the termux-api app. I installed this version: https://github.com/termux/termux-api/actions/runs/6717239830

Perhaps it's time to create a new release?

txoof commented 11 months ago

@mogenson I see that you closed this; I'm having a similar problem, but all of the API tools hang indefinitely.

What was your solution? Would you mind sharing what you did to resolve this?

mogenson commented 11 months ago

Note, termux-api commands do work with a newer build of the termux-api app. I installed this version: https://github.com/termux/termux-api/actions/runs/6717239830

@txoof I uninstalled version 0.51 of the Termux API app and installed a newer build. This solved my problem.

pramodhrachuri commented 9 months ago

@mogenson where can I find the newer build? F-droid and the releases section on github shows older versions. I'm getting the "There was a problem parsing the package" error. The link you mentioned has expired. I got the same parsing error with the new builds as well.

sylirre commented 9 months ago

The most recent builds can be obtained only as GitHub Actions pipeline artifacts: https://github.com/termux/termux-api/actions/runs/7378294041

There was a problem parsing the package"

Make sure you're not trying to install GitHub version over F-Droid. Their signatures incompatible.

Termux app and Termux:API should be from same origin.

pramodhrachuri commented 9 months ago

This worked. Thanks!