-
-
Notifications
You must be signed in to change notification settings - Fork 187
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Resources$NotFoundException thrown when the application is killed by OS #158
Comments
Thanks for the detailed report and pull request. Every bug report should look like this. 🥇 I will have a look myself and comment on the PR. |
Thanks @NiklasMerz ! Have you been able to have a look ? I know that I could be a little bit confusing to understand, but it is quite easy to reproduce it especially on Samsung devices. Thanks in advance ! |
I cannot reproduce this with my phone or the emulator. I probably need to get an older one. Let´s discuss this further in the PR. We need to be careful here. |
@rpanadero, @NiklasMerz The stack trace:
The crashing devices:
|
Please test #178 if it fixes this. |
Closed since #179 fixed this issue. Thank you for contributing! |
Bug report
Description
Hi, I'm facing an issue with this plugin that occurs when the OS kills the application because of memory, for example if the mobile user has many application opened on background at a time. If the Fingerprint authentication fragment is present when the OS kills your application, the application crashes when the user tries to resume it. The crash stacktrace is attached below.
As you will see in the logs, investigating the issue I added a log entry at line 84 of FingerprintAuthenticationDialogFragment class (inside 'onCreateView' method) which helped me to find out what it was really happening.
When everything works well, this log entry is shown with the right application package name:
04-08 11:19:55.140 12681 12681 D FingerprintAuthDialog: packageName: com.okode.demo
But, if the application crashes, this is the log:
04-08 12:11:02.362 29538 29538 D FingerprintAuthDialog: packageName: null
This made me realize that all plugin data, which was kept in memory, had been erased because OS had killed the application while this was on background and when the user tried to resume the application, then crashed trying to get a resource by using an invalid application package name.
These are the steps to reproduce the issue:
I'm gonna try to provide you with a pull request related to this issue and I will try to be as less intrusive as I can. So, feel free to share anything with me.
Environment
Logs
The text was updated successfully, but these errors were encountered: