termux-saf-managedir fails
Nobody has claimed this yet.
- Dominant language
- Java
- Stars
- 4.3k
- Forks
- 920
- PR merge metrics
- No merged PRs in 30d
Description
Report Info
User Action: plugin execution command
Sender: ResultReturner
Report Timestamp: 2026-01-28 08:55:11.318 UTC
Termux:API Error
Error in ResultReturner:
java.io.IOException: Connection refused
at android.net.LocalSocketImpl.connectLocal(Native Method)
at android.net.LocalSocketImpl.connect(LocalSocketImpl.java:259)
at android.net.LocalSocket.connect(LocalSocket.java:162)
at com.termux.api.util.ResultReturner.lambda$returnData$0(SourceFile:250)
at com.termux.api.util.ResultReturner.$r8$lambda$RFR2zSHu5FsJH7JvuCx4CPnUmMY(SourceFile:0)
at com.termux.api.util.ResultReturner$$ExternalSyntheticLambda0.run(SourceFile:0)
at java.lang.Thread.run(Thread.java:1119)
Suppressed: java.lang.Exception: Called by:
at com.termux.api.util.ResultReturner.returnData(SourceFile:239)
at com.termux.api.apis.SAFAPI$SAFActivity.onDestroy(SourceFile:55)
at android.app.Activity.performDestroy(Activity.java:9850)
at android.app.Instrumentation.callActivityOnDestroy(Instrumentation.java:1559)
at android.app.ActivityThread.performDestroyActivity(ActivityThread.java:6913)
at android.app.ActivityThread.handleDestroyActivity(ActivityThread.java:6958)
at android.app.servertransaction.DestroyActivityItem.execute(DestroyActivityItem.java:52)
at android.app.servertransaction.ActivityTransactionItem.execute(ActivityTransactionItem.java:63)
at android.app.servertransaction.TransactionExecutor.executeLifecycleItem(TransactionExecutor.java:169)
at android.app.servertransaction.TransactionExecutor.executeTransactionItems(TransactionExecutor.java:101)
at android.app.servertransaction.TransactionExecutor.execute(TransactionExecutor.java:80)
at android.app.ActivityThread$H.handleMessage(ActivityThread.java:3103)
at android.os.Handler.dispatchMessage(Handler.java:110)
at android.os.Looper.loopOnce(Looper.java:273)
at android.os.Looper.loop(Looper.java:363)
at android.app.ActivityThread.main(ActivityThread.java:9983)
at java.lang.reflect.Method.invoke(Native Method)
at com.android.internal.os.RuntimeInit$MethodAndArgsCaller.run(RuntimeInit.java:632)
at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:975)
Termux:API App Info (Current)
APP_NAME: Termux:API
PACKAGE_NAME: com.termux.api
VERSION_NAME: 0.53.0
VERSION_CODE: 1002
UID: 10402
TARGET_SDK: 28
IS_DEBUGGABLE_BUILD: false
SE_PROCESS_CONTEXT: u:r:untrusted_app_27:s0:c146,c257,c512,c768
SE_FILE_CONTEXT: u:object_r:app_data_file:s0:c146,c257,c512,c768
SE_INFO: default:targetSdkVersion=28:complete
APK_RELEASE: F-Droid
SIGNING_CERTIFICATE_SHA256_DIGEST: 228FB2CFE90831C1499EC3CCAF61E96E8E1CE70766B9474672CE427334D41C42
Termux App Info
APP_NAME: Termux
PACKAGE_NAME: com.termux
VERSION_NAME: 0.119.0-beta.3
VERSION_CODE: 1022
UID: 10402
TARGET_SDK: 28
IS_DEBUGGABLE_BUILD: false
SE_PROCESS_CONTEXT: u:r:untrusted_app_27:s0:c146,c257,c512,c768
SE_FILE_CONTEXT: u:object_r:app_data_file:s0:c146,c257,c512,c768
SE_INFO: default:targetSdkVersion=28:complete
TERMUX_APP_PACKAGE_MANAGER: -
TERMUX_APP_PACKAGE_VARIANT: -
APK_RELEASE: F-Droid
SIGNING_CERTIFICATE_SHA256_DIGEST: 228FB2CFE90831C1499EC3CCAF61E96E8E1CE70766B9474672CE427334D41C42
Device Info
Software
OS_VERSION: 6.6.66-android15-8-abogkiX930XXS3AYJ3-4k
SDK_INT: 36
RELEASE: 16
ID: BP2A.250605.031.A3
DISPLAY: BP2A.250605.031.A3.X930XXS3AYJ3
INCREMENTAL: X930XXS3AYJ3
SECURITY_PATCH: 2025-11-01
IS_TREBLE_ENABLED: true
TYPE: user
TAGS: release-keys
MAX_PHANTOM_PROCESSES: - (Requires DUMP and PACKAGE_USAGE_STATS permission)
MONITOR_PHANTOM_PROCS: true
DEVICE_CONFIG_SYNC_DISABLED: -
Hardware
MANUFACTURER: samsung
BRAND: samsung
MODEL: SM-X930
PRODUCT: gts11uwifieea
BOARD: gts11uwifi
HARDWARE: mt6991
DEVICE: gts11uwifi
SUPPORTED_ABIS: arm64-v8a
Contributor guide
No contributing guide indexed for this repository
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start with ResultReturner.returnData and the SAFAPI$SAFActivity.onDestroy call shown in the stack trace. Reproduce the plugin execution command on the reported Android and Termux versions, then trace why the local socket connection is refused. Done means termux-saf-managedir completes without the reported error and its result is returned.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- java
- Domain
- mobile
- Issue type
- Bug
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Stale
- Clarity
- Needs clarification
- Newbie friendliness
- 25/100