今天,一周后,我开始运行和调试我的应用程序,但出现了一些错误。我在网上搜索时在GitHub上找到了一些解决方案,但它们并没有给我带来太大帮助。 这就是我要得到的-
FAILURE: Build failed with an exception.
* What went wrong:
Could not determine the dependencies of task ':app:compileDebugJavaWithJavac'.
> Could not resolve all task dependencies for configuration ':app:debugCompileClasspath'.
> Could not resolve io.flutter:flutter_embedding_debug:1.0.0-e7b69ced2e2408da86261227a04f09e0c0fe905d.
Required by:
project :app
project :app > project :firebase_auth
project :app > project :cloud_firestore
project :app > project :google_sign_in
project :app > project :firebase_core
project :app > project :firebase_storage
,依此类推... 这是扑扑医生-v
[√] Flutter (Channel master, v1.13.1-pre.59, on Microsoft Windows [Version 10.0.18363.476], locale en-IN)
• Flutter version 1.13.1-pre.59 at C:\Users\acer\flutter
• Framework revision e58dc16d7b (35 hours ago), 2019-12-06 18:21:52 -0800
• Engine revision e7b69ced2e
• Dart version 2.7.0 (build 2.7.0-dev.2.1 a9c77229c2)
[√] Android toolchain - develop for Android devices (Android SDK version 28.0.3)
• Android SDK at C:\Users\acer\AppData\Local\Android\sdk
• Android NDK location not configured (optional; useful for native profiling support)
• Platform android-28, build-tools 28.0.3
• Java binary at: C:\Program Files\Android\Android Studio\jre\bin\java
• Java version OpenJDK Runtime Environment (build 1.8.0_202-release-1483-b03)
• All Android licenses accepted.
[√] Android Studio (version 3.5)
• Android Studio at C:\Program Files\Android\Android Studio
• Flutter plugin version 41.1.2
• Dart plugin version 191.8593
• Java version OpenJDK Runtime Environment (build 1.8.0_202-release-1483-b03)
[√] VS Code (version 1.40.2)
• VS Code at C:\Users\acer\AppData\Local\Programs\Microsoft VS Code
• Flutter extension version 3.7.0
[√] Connected device (1 available)
• AOSP on IA Emulator • emulator-5554 • android-x86 • Android 9 (API 28) (emulator)
我尝试了此处提到的解决方案-https://github.com/flutter/flutter/issues/30573
这是我的pubspec.yaml依赖项-
cupertino_icons: ^0.1.2
firebase_auth: ^0.14.0+5
firebase_core: 0.4.2+1
cloud_firestore: ^0.12.9+4
provider: ^3.1.0+1
flutter_spinkit: "^4.0.0"
google_sign_in: ^4.0.14
firebase_storage: ^3.0.8
答案 0 :(得分:1)
您必须遵循此处的步骤-firebase.google.com/docs/flutter/setup
这里的问题是我的pubspec.yaml文件未启用Analytics(分析)。
firebase_analytics: ^5.0.2
感谢@Benjamin S。