1

I get this error anytime i try to open the apk i get after running flutter build apk, "Error parsing package"

In my AndroidManifest.xml there is android:exported="true" but still gives same issue

This is what i get from the terminal

Font asset "CupertinoIcons.ttf" was tree-shaken, reducing it from 283452 to 1524 bytes (99.5% reduction). Tree-shaking can be disabled by providing the --no-tree-shake-icons flag when building your app. Font asset "MaterialIcons-Regular.otf" was tree-shaken, reducing it from 1645184 to 3956 bytes (99.8% reduction). Tree-shaking can be disabled by providing the --no-tree-shake-icons flag when building your app. Running Gradle task 'assembleRelease'... 14.1s ✓ Built build/app/outputs/flutter-apk/app-release.apk (51.0MB).

Precious Oladele
  • 123
  • 1
  • 1
  • 6

1 Answers1

0

Thats due to a security feature called "Google Play Protect". this could trigger due to various reasons. could be the google play is simply playing it safe. Or may be due to the app is signed with a debug Certificate if you haven't add a proper signing certificate. you can learn more from https://support.google.com/googleplay/answer/2812853?hl=en

Also you can try:

  1. "flutter build web --no-tree-shake-icons "
  2. flutter pub add cupertino_icons
  3. android SDK update
  4. Try to install it on another Android device with higher OS version and better hardware.

I hope your problem is solved. Enjoy your work.

MobileDev
  • 214
  • 7
  • Hello i switched off the google play protect rn but still having same issue and i signed the app also i followed https://docs.flutter.dev/deployment/android, can it be an issue from the mac? – Precious Oladele Aug 19 '23 at 10:54
  • I don't know if it's because of the Mac. Someone using the package in this link said that in this form the problem was solved on the IOS side. You can try this. https://pub.dev/packages/in_app_update – MobileDev Aug 19 '23 at 11:04
  • could it be this 17 packages have newer versions incompatible with dependency constraints. Try `flutter pub outdated` for more information. – Precious Oladele Aug 19 '23 at 11:08
  • I've never encountered such a problem before. So I'm not sure. But you can try the solution you mentioned. – MobileDev Aug 19 '23 at 11:13