我是flutter的初学者,我正在使用android studio创建我的flutter应用程序,并且我已经完成了我的应用程序!
我的应用程序在模拟器上运行没有问题,我需要将我的应用程序上载到Google Play和应用商店,当我为应用程序捆绑包构建应用程序时,它可以正常工作,但是当我为apk生成时,出现错误!
这是错误:
BUILD FAILED in 1m 47s
Running Gradle task 'assembleRelease'... 108.1s
The built failed likely due to AndroidX incompatibilities in a plugin. The tool is about to
try using Jetfier to solve the incompatibility.
Building plugin cloud_firestore...
Running Gradle task 'assembleAarRelease'...
The plugin cloud_firestore could not be built due to the issue above.
Process finished with exit code 1
当然我已经为AndroidX创建了我的应用程序,所以我的应用程序已经包含AndroidX(gradle.properties)文件:
org.gradle.jvmargs=-Xmx1536M
android.enableR8=true
android.useAndroidX=true
android.enableJetifier=true
我正在尝试创建新项目并移动我的lib文件和pubspec.yaml文件,但是遇到相同的问题。
我的pubspec.yaml文件:
version: 1.0.0+1
environment:
sdk: ">=2.1.0 <3.0.0"
dependencies:
flutter:
sdk: flutter
firebase_auth: 0.15.3
firebase_storage: 3.1.1
cloud_firestore: 0.13.4
shared_preferences: 0.5.4+6
flutter_offline: 0.3.0
provider: 3.1.0
simple_animations: ^1.1.3
page_transition: 1.1.4
cupertino_icons: 0.1.3
gradient_app_bar: 0.0.1
fluttertoast: 3.1.1
flutter_spinkit: 4.0.0
flutter_launcher_icons: 0.7.3
rflutter_alert: 1.0.3
url_launcher: 4.1.0
flutter_speed_dial: 1.2.5
image_picker: 0.6.2
file_picker: 1.4.3+2
validators: 2.0.0+1
dio: 3.0.8
flutter_plugin_pdf_viewer: 1.0.7
dependency_overrides:
firebase_core: 0.4.4