Skip to content

Strange behaviour while using RUN_COMMAND Intent #3640

Closed Answered by agnostic-apollo
coderGtm asked this question in Q&A
Discussion options

You must be logged in to vote

Ah, when you enabled a wakelock in termux, it would have asked to be exempted from battery optimizations (REQUEST_IGNORE_BATTERY_OPTIMIZATIONS), that would be why error is not triggering any more. Draw over apps permission should have same effect. Could revoke it from Android Settings -> Apps -> Termux -> Advanced -> Battery -> Battery optimizations -> Termux -> Don't optimize. Wakelock permission (WAKE_LOCK) itself is automatically granted.

https://developer.android.com/guide/components/foreground-services#background-start-restriction-exemptions

Replies: 1 comment 3 replies

Comment options

You must be logged in to vote
3 replies
@coderGtm
Comment options

@agnostic-apollo
Comment options

Answer selected by agnostic-apollo
@agnostic-apollo
Comment options

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
2 participants