Closed valerii-sovytskyi closed 2 years ago
Interesting. Didn't get this error.... Anyway, I have added into wiki. Thanks a lot
Sorry, but I didn't test it well, this fix is not working, the crash was fixed, but the Scanner is not working I guess because I removed MLKit at all, I will update you on my investigation
@JimmyPun610 The problem was here Android Options -> Code shrinker -> not to be r8 in my case it's an empty selector.
Please, remove what I suggested.
Xamarin android that targets Android 12 (API 31)
The issue: For my case I was not able to RUN the application on release mode, and by researching I found that the problem was next:
Unable to get provider com.google.mlkit.common.internal.MlKitInitProvider
To fix this issue I needed to update the AndroidManifest.xmlJust add this code~~
<provider android:name="com.google.mlkit.common.internal.MlKitInitProvider" android:authorities="${your app id}.mlkitinitprovider" tools:node="remove" /> <meta-data android:name="com.google.mlkit.vision.DEPENDENCIES" android:value="barcode" />
~~And inside Manifestxmlns:tools="http://schemas.android.com/tools"
I'm suggesting to update the Wiki section so developers will add it to the AndroidManifestThe fix found here https://developers.google.com/ml-kit/vision/barcode-scanning/androidUPD: The fix for my case was to set Code shrinker to be empty, not R8