-
Notifications
You must be signed in to change notification settings - Fork 154
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
Android 12 support #887
Comments
Hello @SebaDro sir, I checked on this bug researched it, and did some coding.
The request permission code was in the
I researched about it too, and after getting done with the permission issues, it was crashing because of not specifying the mutability of each pending intent that is being used. This results in a crash.
more info here I did add some code to handle this issue but I was still facing some issues, I would talk about it more when I have proper information about it. |
Hey @cdhiraj40. Thanks for your elaborations on this issue. It sounds like you are on the right track. Could you please create a work in progress pull request with the coding you have done so far? Then we can use the pull request to discuss further about possible approaches for fixing the issue. |
Sure @SebaDro sir, I will create a PR soon for this. |
Has been fixed with #910 and proofed as working. |
Description
Up to now, the app does not support Android 12 very well. Several issues have been reported regarding the Bluetooth permission management and OBDII connections.
As stated in the official Android documentation, Bluetooth permission management has changed for Android 12 devices. This has already been addressed by a5b531e. However, the solution does not work perfectly, so that abrupt app crashes still occur.
In addition, these crashes are not logged and therefore do not appear inthe crash report which makes it hard to retrace the failure.
Branches
master, develop
How to reproduce
If you have had the enviroCar app already in use on a device with Android version <12 and upgrade to Android 12, you will notice the first crash when trying to open the Bluetooth selection screen. A helpful workaround for this issue is a clean installation (remove app from your deivce and install again from Google Playstore) in combination with manually revoking enviroCar app permissions from you device settings. By doing so, new permissions will be queried the first time you will visit the Bluetooth selection screen. However, when you try to start recording, the app still crashes abrupt.
How to fix
Refine Bluetooth permission management according to Android 12 requirements and add a more sensible logging that takes into account abrupt crashes caused by permission issues.
Special thanks to @ChrissW-R1 who extensively tested the behavior on an Android 12 device and reported the issues.
The text was updated successfully, but these errors were encountered: