Atooma plugin stops working - android

I made a simple plugin for Atooma: performer plugin to change a wallpaper photo upon trigger: Screen On. After it triggered this action couple of times after some time it stopped working: in Atooma notification it always says that it has been triggered but my performer doesn't get called: I made sure by putting couple of log calls inside performer.
I checked the logs and these may provide some clue:
threadid=17 (Thread-6653): calling run()
android.os.DeadObjectException
at android.os.BinderProxy.transact(Native Method)
at com.atooma.plugin.r.a(Unknown Source)
at com.atooma.plugin.z.a(Unknown Source)
at com.atooma.engine.t.run(Unknown Source)
at java.lang.Thread.run(Thread.java:838)
threadid=17: exiting
This log message appears every time when trigger is activated ('screen on' in my current case)
Another symptom is that when I look at my task in Atooma, I don't see DO part where my performer action was - no icons, after DO nothing shows (description bellow is ok). When I try to edit it - Atooma crashes: dialog message appears: "Unfortunately, Atooma has stopped. Report/Ok". If I click OK Atooma obviously get restarted showing me again my task, icons for my performer are still missing but when I click edit it works this time. Performer again works upon trigger but after a while it stops working again with same exceptions as above listing from log every time it gets triggered.
Any suggestion is appreciated

Yes, I saw the same problem. It happens when the Atooma service died or something internal to Atooma happens (the plug communicates with Atooma via aidl remote service). The only option is to uninstall and install the plug again. Report this behavior to the Atooma team.

Related

DeadSystemException start service Android 7

For the past few weeks, I have on my crash reporter:
Fatal Exception: java.lang.RuntimeException: Unable to start service com.####.MyService#ef705d8 with Intent { act=HIDE cmp=com.####/.MyService (has extras) }: java.lang.RuntimeException: android.os.DeadSystemException
at android.app.ActivityThread.handleServiceArgs(ActivityThread.java:3344)
at android.app.ActivityThread.-wrap21(ActivityThread.java)
at android.app.ActivityThread$H.handleMessage(ActivityThread.java:1583)
at android.os.Handler.dispatchMessage(Handler.java:102)
at android.os.Looper.loop(Looper.java:154)
at android.app.ActivityThread.main(ActivityThread.java:6121)
at java.lang.reflect.Method.invoke(Method.java)
at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:889)
at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:779)
This crash is present on:
all Samsung devices 7.0
all Nexus devices on 7.1.2
Note:
It is not due to a recent update of our application, just an OS updates on theses phones.
It is a very very frequent crashes (by far our biggest).
Our users don't report crashes than before (is this crash actually visible for the user?)
We are not able to reproduce it on our side
As you can see into the stack trace, the code impacted is system only. Not much I can do from my side to try and catch and handle the issue.
I checked the thread Android DeadSystemException but that doesn't help me much.
I know that DeadSystemException is:
The core Android system has died and is going through a runtime restart. All running apps will be promptly killed.
Is there anything we can do but to say "that's system, we cannot do anything"?
When the device is being restarted, you cannot run an app. Any app, not just yours but any given app cannot run when the device is restarting. AFAIK it occurs when you try to do something when the system crashes. Meaning if the system crashes and as it restarts your app starts a service or does something you get that error.
Meaning the exception is not connected to your app, but the Android OS and there is nothing you can do about it.
The crash being related to starting a service is because that is what your app did when the system crashed.
So: The error is something the system threw because your app did something when the system did a run-time reboot. There is nothing you can do about this, as you cannot control the Android OS from an app.
I've had the same issue. I implemented a service that uses the android SensorService. In some point of the time, two things happened but I still don't know which one caused the other. 1) The runtime restarted 2) The android SensorService died. I have implemented a default unhandled exceptions handler because I was debugging some other stuff on my app. I noticed that such handler, at least sometimes was catching that exception.
I followed this tutorial to implement it https://doandroid.wordpress.com/2011/11/19/writing-crash-reports-into-device-sd-card/
So, supposing that you implement this handler and it is actually being called when the system dies, you can add some sort of validations inside the handler such that if the exception is the DeadSystemException, you can set up an alarm to restart your application in let's say, 5 minutes or something.
This is of course not an ideal solution, but at least might be a workaround to your problem until you figure out what is really going on with the system.
Some information about how to restart you app programmatically:
Force application to restart on first activity
Your app crashed because of android OS system dies.
Here is the reference.
https://developer.android.com/reference/android/os/DeadSystemException
The core Android system has died and is going through a runtime restart. All running apps will be promptly killed.

Logcat full of "Wtf, activity ActivityRecord" entries

I am getting thousands of the following warning message in my logcat, and it's crowding out the messages that I'm actually looking for:
W/ActivityManager﹕ Wtf, activity ActivityRecord{4338cd90 u0 us.bridgeses.Minder.debug/us.bridgeses.Minder.MainListActivity t269 f} in proc activity list not using proc ProcessRecord{4289a348 4821:us.bridgeses.Minder.debug/u0a246}?!?
Possibly related, my phone is now occassionally popping up the "Waiting for debugger process" dialog even when my phone is unplugged and the app is in the background. It only stops if I uninstall it, and starts up again the next time I debug. Any ideas?
Edit:
I just commented out my entire MainListActivity class. My app is now literally doing nothing except creating an empty Activity. I'm still getting tons of this message, and I'm still getting this message.
Edit 2:
This is getting really weird. I uninstalled the debug app, did not reinstall it, and I'm still getting this message.
This message comes from the Android OS. It happens when your activity is not destroyed correctly. Therefore the ActivityRecord is still there, but the corresponding proc is not. By rebooting, all records will lost, so you would not see any of these errors.
Typically this happens when a active/foreground activity component is being disabled. Such as calling packageManager.setComponentEnabledSetting() method to disable current active activity component.
I restarted my phone and the error has not recurred for 10 minutes. It's not really an answer, but I guess it's a resolution.

Calling a method in the system process without a qualified user error

I'm using the notification listener service in android 4.4 and I'm coming across an error that causes my app to stop getting notifications posted.
It's fairly random, but when it happens I'm seeing:
12-31 01:40:44.080 21680-21680/? W/ContextImpl﹕ Calling a method in the system process without a qualified user:
android.app.ContextImpl.sendOrderedBroadcast:1192
android.app.ContextImpl.sendOrderedBroadcast:1183
android.content.ContextWrapper.sendOrderedBroadcast:390
com.android.settings.applications.ProcessStatsDetail.checkForceStop:314
com.android.settings.applications.ProcessStatsDetail.onResume:108
in the logs.
I can even recreate this by just entering the "process stats" section of the developer tools on the phone. As soon as I select an app that uses the notification listener the puts up this warning and unbinds and destroys the service and when it recreates is it doesn't always pick up on events again.
I'm not sure why this would happen, can anyone shed any light?
1) the NotificationListenerService is started by the system and the code for sendOrderedBroadcast throws a warning if it was called by the system process (here)
2) That is just a warning though. There is probably a crash somewhere else in your code. When a NotificationListenerService crashes, Android doesn't restart it unless you toggle the permission or restart your phone. Look for another crash and try either of those methods to restart it if it has. Starting it yourself will not work.
Check your AIDL Package name, for me the Package name in client and server were mismatched. Hope it help somebody

Logcat messages disappear after a short time

Sometimes eclipse logcat messages disappear after closing the app for a short time. (Mostly not so short.) How to make it never disappear automatically?
EDIT: My device is still attached. And how to set it to show log even after device disattach and clear just before next launch?
this is also happening with me. The device is attached. And so all the internal actions are getting logged and the error message disappears very quickly. You should try the following (it worked for me)
Restart Eclipse (as stated here Why logcat is not showing anything?)
if 1 does not work, you may try to increase the logcat message size. From Window > Preferences > Android > LogCat (increase size to more than 5000)
First one worked for me. In this way also you need not to detach the device everytime you deploy the app from eclipse. Regarding, the other question - you can always clear the existing log from [Clear log] button.

Application throws an error after relaunch

My application throws an error when I attempt to start it from "Recent applications". Problems :
Error appears only if application was inactive (stopped) for a long time (approximately one hour). I can't catch this error by myself - when I'm killing process by myself and then relaunched it there is no errors!
I can't see Exception log in debugger, since it's disconnects after so long time.
How can I catch such kind of errors in debugger? Looks error appears only when OS kills application by itself.
EDIT
I didn't overrided onResume method. Just onStart, and there is nothing special except instantination of my SQLiteOpenHelper.
even if your app is in paused/stopped state, log cat will still be working as long as device is connected. make sure you selected all logs options in windows > devices > all logs instead of windows > devices > com.your.project .
so when you will try to relaunch crash must be recorded in logCat
if still have any issue, install logcat app from market and refer it for logs.
Sounds like there might be an issue in your
OnResume
call. What is your application doing? Is it using a location manager? Does it have services or threads that need to be restarted? More infomation please.
Look through the Android application lifecycle chart:
http://developer.android.com/reference/android/app/Activity.html
It should help you understand what's going on. If all else fails, add a lot of logging to logcat and see what the output looks like on your end. As long as you don't unplug the device, you shouldn't lose that in Eclipse. If you do, you can always run "adb logcat" from the command line or shell to see exactly what's happening.

Categories

Resources