Open ralfeus opened 1 year ago
This happens because this feature is still not supported as stated in the Readme
.
This feature is called Long running task and need special settings as stated in the official Android doc
https://developer.android.com/guide/background/persistent/how-to/long-running
Sorry, I haven't found anything about long running tasks in readme. Is it going to be supported? Is there same situation with iOS? I don't run it on iOS at the moment but it definitely will come to picture in the future.
Has anyone found a solution for this?
Version
Describe the error I start the background task, which is supposed to be long running (as long as device is running). At some random point I get the error:
That happens both in emulator and physical device. I'm not sure if this error is in main isolate or background one. But having that the application doesn't crash whilst background isolate does I assume it's occurred in the background isolate.
I wrapped whole background entry point to try-catch but this exception isn't caught. And yeah, it seems to be a Java exception so I didn't really expect it to be caught by Dart code.
The background entry point looks like this:
Output of
flutter doctor -v