简体   繁体   English

我在运行我的应用程序时收到此 E/flutter (25055) 错误(Flutter,FireBase

[英]I am getting this E/flutter (25055) error when I am running my App (Flutter , FireBase

I am getting this E/flutter (25055) error when I am running my App (Flutter, fireBase我在运行我的应用程序时收到此 E/flutter (25055) 错误(Flutter,fireBase

I tried Updating my flutter but still, I am getting the same logs and these logs are making my App unstable and the App is crashing a lot我尝试更新我的 flutter 但我仍然收到相同的日志,这些日志使我的应用程序不稳定并且应用程序经常崩溃

E/flutter (25055): [ERROR:flutter/lib/ui/ui_dart_state.cc(199)] Unhandled Exception: Bad state: field does not exist within the DocumentSnapshotPlatform
E/flutter (25055): #0      DocumentSnapshotPlatform.get._findKeyValueInMap (package:cloud_firestore_platform_interface/src/platform_interface/platform_interface_document_snapshot.dart:86:7)
E/flutter (25055): #1      DocumentSnapshotPlatform.get._findComponent (package:cloud_firestore_platform_interface/src/platform_interface/platform_interface_document_snapshot.dart:104:41)
E/flutter (25055): #2      DocumentSnapshotPlatform.get (package:cloud_firestore_platform_interface/src/platform_interface/platform_interface_document_snapshot.dart:120:26)
E/flutter (25055): #3      _JsonDocumentSnapshot.get (package:cloud_firestore/src/document_snapshot.dart:92:48)
E/flutter (25055): #4      _JsonDocumentSnapshot.[] (package:cloud_firestore/src/document_snapshot.dart:96:40)
E/flutter (25055): #5      _MyHomePageState.getLists (package:form_app/pages/home.dart:518:30)
E/flutter (25055): <asynchronous suspension>
E/flutter (25055): #6      _MyHomePageState._getUnitNamesData (package:form_app/pages/home.dart:495:33)
E/flutter (25055): <asynchronous suspension>
E/flutter (25055): 

my Flutter doctor我的 Flutter 医生

C:\src\flutter\bin\flutter.bat doctor --verbose [√] Flutter (Channel stable, 2.2.3, on Microsoft Windows [Version 10.0.19041.450], locale en-US) • Flutter version 2.2.3 at C:\src\flutter • Framework revision f4abaa0735 (7 weeks ago), 2021-07-01 12:46:11 -0700 • Engine revision 241c87ad80 • Dart version 2.13.4 C:\src\flutter\bin\flutter.bat doctor --verbose [√] Flutter(频道稳定,2.2.3,在 Microsoft Windows [版本 10.0.19041.450],区域设置 en-US)• 88385189659.883 版本 2 C:\src\flutter • 框架修订版 f4abaa0735(7 周前),2021-07-01 12:46:11 -0700 • 引擎修订版 241c87ad80 • Dart 版本 2.13.4

[√] Android toolchain - develop for Android devices (Android SDK version 30.0.2) • Android SDK at C:/Users/afran/AppData/Local/Android/Sdk • Platform android-30, build-tools 30.0.2 • ANDROID_HOME = C:/Users/afran/AppData/Local/Android/Sdk • Java binary at: C:\Program Files\Android\Android Studio\jre\bin\java • Java version OpenJDK Runtime Environment (build 11.0.8+10-b944.6842174) • All Android licenses accepted. [√] Android toolchain - develop for Android devices (Android SDK version 30.0.2) • Android SDK at C:/Users/afran/AppData/Local/Android/Sdk • Platform android-30, build-tools 30.0.2 • ANDROID_HOME = C:/Users/afran/AppData/Local/Android/Sdk • Java 二进制文件位于:C:\Program Files\Android\Android Studio\jre\bin\java • Java 版本 OpenJDK 运行时环境(build 11.0.8+1 b944.6842174) • 接受所有 Android 许可证。

[√] Chrome - develop for the web • Chrome at C:\Program Files (x86)\Google\Chrome\Application\chrome.exe [√] Chrome - 为 web 开发 • Chrome 位于 C:\Program Files (x86)\Google\Chrome\Application\chrome.exe

[√] Android Studio (version 4.1.0) • Android Studio at C:\Program Files\Android\Android Studio • Flutter plugin can be installed from: https://plugins.jetbrains.com/plugin/9212-flutter • Dart plugin can be installed from: https://plugins.jetbrains.com/plugin/6351-dart • Java version OpenJDK Runtime Environment (build 11.0.8+10-b944.6842174) [√] Android Studio(版本 4.1.0) • Android Studio 位于 C:\Program Files\Android\Android Studio • Flutter 插件可以从以下位置安装: https://plugins.jetbrains.com/18519685 •插件可以从以下位置安装: https://plugins.jetbrains.com/plugin/6351-dart • Java 版 OpenJDK 运行时环境(build 11.0.8+10-b944.6842174)

[√] IntelliJ IDEA Ultimate Edition (version 2020.2) • IntelliJ at F:\IntelliJ IDEA 2020.2.3 • Flutter plugin can be installed from: https://plugins.jetbrains.com/plugin/9212-flutter • Dart plugin can be installed from: https://plugins.jetbrains.com/plugin/6351-dart [√] IntelliJ IDEA Ultimate Edition(版本2020.2) • IntelliJ at F:\IntelliJ IDEA 2020.2.3 • Flutter 插件可以安装自: https://plugins.jetbrains.com/plugin/9212-flutter • Dart 插件可以安装自: https://plugins.jetbrains.com/plugin/6351-dart

[√] VS Code (version 1.55.2) • VS Code at C:\Users\afran\AppData\Local\Programs\Microsoft VS Code • Flutter extension version 3.21.0 [√] VS Code(版本 1.55.2) • VS Code 位于 C:\Users\afran\AppData\Local\Programs\Microsoft VS Code • Flutter 扩展版本 3.21.0

[√] Connected device (2 available) • Android SDK built for x86 (mobile) • emulator-5554 • android-x86 • Android 10 (API 29) (emulator) • Chrome (web) • chrome • web-javascript • Google Chrome 92.0.4515.131 [√] 已连接设备(可用 2 个)• Android SDK 为 x86(移动设备)构建 • emulator-5554 • android-x86 • Android 10 (API 29)(模拟器)• Chrome(网络)• chrome • web-javascript • Google Chrome 92.0.4515.131

• No issues found! • 没有发现问题!

My App dependencies我的应用程序依赖项

dependencies:
  flutter:
    sdk: flutter
  flutter_spinkit: ^5.0.0
  geolocator: ^7.0.1
  #geolocation: ^1.1.2
  cloud_firestore: ^2.4.0
  firebase_storage: ^10.0.1
  permission_handler: ^8.1.4+2
  firebase_core: ^1.0.1
  url_launcher: ^6.0.2
  firebase_auth: ^3.0.1
  provider: ^5.0.0
  google_fonts: ^2.0.0
  shared_preferences: ^2.0.4
  connectivity: ^3.0.2
  mailer: ^5.0.1
  firebase_messaging: ^10.0.4
  flutter_local_notifications: ^5.0.0+1

The exception says the problem:异常说明了问题:

Unhandled Exception: Bad state: field does not exist within the DocumentSnapshotPlatform

Also you have the call methods:你也有调用方法:

E/flutter (25055): #0      DocumentSnapshotPlatform.get._findKeyValueInMap (package:cloud_firestore_platform_interface/src/platform_interface/platform_interface_document_snapshot.dart:86:7)
E/flutter (25055): #1      DocumentSnapshotPlatform.get._findComponent (package:cloud_firestore_platform_interface/src/platform_interface/platform_interface_document_snapshot.dart:104:41)
E/flutter (25055): #2      DocumentSnapshotPlatform.get (package:cloud_firestore_platform_interface/src/platform_interface/platform_interface_document_snapshot.dart:120:26)
E/flutter (25055): #3      _JsonDocumentSnapshot.get (package:cloud_firestore/src/document_snapshot.dart:92:48)
E/flutter (25055): #4      _JsonDocumentSnapshot.[] (package:cloud_firestore/src/document_snapshot.dart:96:40)
E/flutter (25055): #5      _MyHomePageState.getLists (package:form_app/pages/home.dart:518:30)
E/flutter (25055): <asynchronous suspension>
E/flutter (25055): #6      _MyHomePageState._getUnitNamesData (package:form_app/pages/home.dart:495:33)
E/flutter (25055): <asynchronous suspension>
E/flutter (25055): 

You have to check at these rows what happens.您必须检查这些行会发生什么。 We can't debug this because we don't have the code.我们无法调试它,因为我们没有代码。 You ask for a field that is not existing so it throws this exception.您要求一个不存在的字段,因此它会抛出此异常。

暂无
暂无

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

相关问题 为什么我在 iOS(颤振应用程序)中收到 Firebase AppCheck 错误 - Why am I getting a Firebase AppCheck error in iOS (Flutter app) 我在尝试将数据从云 Firestore 带到我的 flutter 应用程序时遇到此错误 - I am getting this error while am trying to bring data from cloud firestore to my flutter app 为什么我无法将我的 flutter iOS 应用程序添加到我的 firebase 项目中? - Why am I unable to add my flutter iOS app to my firebase project? 我正在尝试在我的 React 应用程序中安装 firebase 并收到此错误 - I am trying to install firebase in my react app and getting this error 将日期数据上传到 flutter 中的 firestore 时出现错误 - I am getting error while uploading date data to firestore in flutter 为什么我的 flutter firebase 身份验证有问题? - Why am I having issues with my flutter firebase authentification? 为什么我在使用 firebase 时收到尝试导入错误? - Why am I getting the attempted import error when using firebase? 在我的 mac 上运行 flutterfire configure 命令时出现错误 - I am getting an error when running the flutterfire configure command on my mac 我正在尝试向我的应用程序添加身份验证,但这样做时出现以下映射错误: - I am trying to add authentication to my application, and I am getting the following mapping error when doing so: Flutter,当我从 firebase 消息发送通知时出现此错误并且我的应用程序冻结 - Flutter, when i send notification from firebase messaging i get this error and my app freeze
 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM