Hello everyone, I am facing an issue where my app ...
# android
r
Hello everyone, I am facing an issue where my app is being killed, and in the Exit Information, I see the following details: • Reason:
OTHER_REASON
Description:
ScreenOffCheckKill 26m3s4ms (26.33344%) threshold 2.0%
The issue occurs when a*fter screen turns off, app in background.* The description in the exit logs suggests ScreenOffCheckKill, but I couldn’t find any official documentation explaining this behavior. • What exactly does
ScreenOffCheckKill
mean, and why does it happen? • Is this a system-level restriction or a configurable setting? • How can I prevent my app from getting killed due to this reason? • Any pointers to official documentation or similar cases would be highly appreciated. Thanks in advance for any insights!
not kotlin but kotlin colored 4
t
Mmmm I believe this happens when the watch dog (OS program to manage memory) is deciding on whether to close your app due to memory restrictions, doze mode (while device is locked), and low memory (meaning your app is using allot of memory) Please check for any logs referring to memory constraints
r
Since this is a system app, I want it to keep running in the background and avoid being killed by the OS. I have checked for memory usage logs but need guidance on how to bypass or handle this restriction for a system app Are there any system-level settings, permissions, or configurations that allow unrestricted background execution?
b
Running int he back ground is tricky, especially on iOS. the platform will be aggressive about not letting that happen. Android as well, but the rules are different. I suggest you studio the Apple docs on what conditions background is allowed. A lot might depend on what you are doing int he background.
c
Image from iOS.jpg