On Android 9 Plugin Getting IllegalStateException

16 views
Skip to first unread message

whitedavidp

unread,
Jul 21, 2020, 6:21:25 PM7/21/20
to Tasker
I am trying to use this plugin on my Android 9 device. On Android 4, 5, and 6 it works wonderfully and I highly recommend it. But on Android 9 I think it is falling prey to Google restrictions on background server stuff. I am not sure if this is an issue with the plugin per se, or with the adapter code for Tasker. I do see something similar looking here on the AutoApps forum.

Any suggestions? I will also post in the Tasker Developer group in case this is not the right spot.

Cheers

2020-07-21 08:59:37.907 19456-19539/com.ecmelberk.taskerhttpserver I/TaskerHTTPServerPlugin: Got request to /
2020-07-21 08:59:37.907 19456-19539/com.ecmelberk.taskerhttpserver D/TaskerHTTPServerPlugin: body is hello
2020-07-21 08:59:37.907 19456-19539/com.ecmelberk.taskerhttpserver D/TaskerHTTPServerPlugin: query is null
2020-07-21 08:59:37.944 19456-19539/com.ecmelberk.taskerhttpserver E/fi.iki.elonen.NanoHTTPD: Communication with the client broken, or an bug in the handler code
java.lang.IllegalStateException: Not allowed to start service Intent { act=com.twofortyfouram.locale.intent.action.REQUEST_QUERY flg=0x10000000 cmp=com.whitedavidp.launchgooglevoiceassist/com.joaomgcd.taskerm.plugin.ServiceRequestQuery (has extras) }: app is in background uid null
at android.app.ContextImpl.startServiceCommon(ContextImpl.java:1604)
at android.app.ContextImpl.startService(ContextImpl.java:1559)
at android.content.ContextWrapper.startService(ContextWrapper.java:664)
at com.joaomgcd.taskerpluginlibrary.condition.TaskerPluginRunnerCondition$Companion.requestQueryThroughServicesAndGetSuccessPackages(TaskerPluginRunnerCondition.kt:106)
at com.joaomgcd.taskerpluginlibrary.condition.TaskerPluginRunnerCondition$Companion.requestQuery(TaskerPluginRunnerCondition.kt:92)
at com.joaomgcd.taskerpluginlibrary.extensions.PublicKt.requestQuery(Public.kt:41)
at com.ecmelberk.taskerhttpserver.http.HTTP.serve(HTTP.kt:31)
at fi.iki.elonen.NanoHTTPD$HTTPSession.execute(NanoHTTPD.java:945)
at fi.iki.elonen.NanoHTTPD$ClientHandler.run(NanoHTTPD.java:192)
at java.lang.Thread.run(Thread.java:764)

whitedavidp

unread,
Jul 22, 2020, 12:00:16 PM7/22/20
to Tasker
Ok, I noticed here that there was a revision to the Tasker Plugin Library to version 0.3.2 to address this particular problem.

So no longer crashing the plugin. However, am still seeing this in logcat and the event is not being fired in Tasker:

2020-07-22 08:36:08.033 1619-3864/? W/ActivityManager: Background start not allowed: service Intent { act=com.twofortyfouram.locale.intent.action.REQUEST_QUERY flg=0x10000000 cmp=com.whitedavidp.launchgooglevoiceassist/com.joaomgcd.taskerm.plugin.ServiceRequestQuery (has extras) } to com.whitedavidp.launchgooglevoiceassist/com.joaomgcd.taskerm.plugin.ServiceRequestQuery from pid=20599 uid=10498 pkg=com.ecmelberk.taskerhttpserver startFg?=false

What is strange here is the component that seems to be invoked (com.whitedavidp.launchgooglevoiceassist). This is an app factory app that I created. I have disabled it and after doing so Tasker does seem to get the event fired by the plugin.

But I have another app factory app that, when installed does not suffer this issue. However, if I re-enable the com.whitedavidp.launchgooglevoiceassist the issue returns.

So is this some problem in the Tasker Plugin Library?

Thanks for any tips/help in resolving this. I do really want to use this app factory app.
Reply all
Reply to author
Forward
0 new messages