I'm getting an error for a Flutter project. I will start deactivating plugins one by one and hopefully find if one of them is causing the problem. Until then I'll leave this here in case anybody has suggestions.
Accessing hidden method Lsun/misc/Unsafe;->putObject(Ljava/lang/Object;JLjava/lang/Object;)V (greylist, linking, allowed)
Accessing hidden method Lsun/misc/Unsafe;->getInt(Ljava/lang/Object;J)I (greylist, linking, allowed)
E/GoogleMapController(29124): Cannot enable MyLocation layer as location permissions are not granted
dependencies:
flutter:
sdk: flutter
firebase_auth: ^0.15.5+2
cloud_firestore: ^0.13.5
firebase_storage: ^3.1.3
firebase_core: ^0.4.4+3
provider: ^4.1.2
google_sign_in: ^4.4.6
google_maps_flutter: ^0.5.28
latlong: ^0.6.1
flappy_search_bar: ^1.7.2
http: ^0.12.1
image_cropper: ^1.2.1
image_picker: ^0.6.3+4
geolocator: ^5.3.1
Doctor summary (to see all details, run flutter doctor -v):
[✓] Flutter (Channel stable, v1.17.1, on Mac OS X 10.15.4 19E287, locale en-RO)
[✓] Android toolchain - develop for Android devices (Android SDK version 29.0.3)
[✓] Xcode - develop for iOS and macOS (Xcode 11.3.1)
[!] Android Studio (version 3.5)
✗ Flutter plugin not installed; this adds Flutter specific functionality.
✗ Dart plugin not installed; this adds Dart specific functionality.
[✓] VS Code (version 1.45.1)
[✓] Connected device (1 available)
! Doctor found issues in 1 category.
Opening the Android app with Android Studio showed the following notice:
Compilation is not supported for following modules: cloud_firestore, cloud_firestore_web, firebase_auth,
firebase_core, firebase_auth_web, firebase_core_web, google_maps_flutter, flutter_plugin_android_lifecycle,
google_sign_in, google_sign_in_web,
location.
Unfortunately you can't have non-Gradle Java modules and Android-Gradle modules in one project.
According to Flutter team's response, it's an Android protobuf issue: https://github.com/flutter/flutter/issues/27095#issuecomment-722857855.
It's been fixed in Android 11: https://android-review.googlesource.com/c/platform/art/+/1294616/.
You can fix this by turning off the backup. Add this tag on your file "android > app > src > debug > AndroidManifest.xml":
<application android:allowBackup="false">
Run
flutter clean
flutter run
flutter create .
Here is some information about your problem https://developer.android.com/guide/topics/data/autobackup .
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With