-
Notifications
You must be signed in to change notification settings - Fork 4k
🐛 [firebase_core] Firebase crashes on iOS #5856
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Comments
Hi @CEO-CGS |
Hello @markusaksli-nc. Thank you for your quick response. Here it is - Flutter SDK 2.0.5-0.0.pre.1
gig 1.0.0+1
dependencies:
- cloud_firestore 0.16.0+1 [flutter meta quiver firebase_core firebase_core_platform_interface cloud_firestore_platform_interface cloud_firestore_web]
- cupertino_icons 1.0.2
- email_validator 2.0.1
- firebase_auth 0.20.1 [meta firebase_core firebase_core_platform_interface firebase_auth_platform_interface firebase_auth_web flutter]
- firebase_core 0.7.0 [firebase_core_platform_interface flutter quiver meta firebase_core_web]
- flutter 0.0.0 [characters collection meta typed_data vector_math sky_engine]
- flutter_launcher_icons 0.9.0 [args image path yaml]
dev dependencies:
- flutter_test 0.0.0 [flutter test_api path fake_async clock stack_trace vector_math async boolean_selector characters charcode collection matcher meta source_span stream_channel string_scanner term_glyph typed_data]
transitive dependencies:
- archive 3.1.2 [crypto path]
- args 2.0.0
- async 2.5.0 [collection]
- boolean_selector 2.1.0 [source_span string_scanner]
- characters 1.1.0
- charcode 1.2.0
- clock 1.1.0
- cloud_firestore_platform_interface 3.0.2 [flutter meta collection firebase_core plugin_platform_interface]
- cloud_firestore_web 0.3.0+2 [flutter flutter_web_plugins http_parser meta firebase_core firebase_core_web cloud_firestore_platform_interface js]
- collection 1.15.0
- crypto 3.0.1 [collection typed_data]
- fake_async 1.2.0 [clock collection]
- firebase_auth_platform_interface 3.1.0 [flutter meta firebase_core plugin_platform_interface]
- firebase_auth_web 0.3.3 [flutter flutter_web_plugins meta http_parser intl firebase_core firebase_core_web firebase_auth_platform_interface js]
- firebase_core_platform_interface 3.0.1 [flutter meta plugin_platform_interface quiver]
- firebase_core_web 0.2.1+3 [firebase_core_platform_interface flutter flutter_web_plugins meta js]
- flutter_web_plugins 0.0.0 [flutter js characters collection meta typed_data vector_math]
- http_parser 3.1.4 [charcode collection source_span string_scanner typed_data]
- image 3.0.2 [archive meta xml]
- intl 0.16.1 [path]
- js 0.6.3
- matcher 0.12.10 [stack_trace]
- meta 1.3.0
- path 1.8.0
- petitparser 4.1.0 [meta]
- plugin_platform_interface 1.0.3 [meta]
- quiver 2.1.5 [matcher meta]
- sky_engine 0.0.99
- source_span 1.8.0 [charcode collection path term_glyph]
- stack_trace 1.10.0 [path]
- stream_channel 2.1.0 [async]
- string_scanner 1.1.0 [charcode source_span]
- term_glyph 1.2.0
- test_api 0.2.19 [async boolean_selector collection meta path source_span stack_trace stream_channel string_scanner term_glyph matcher]
- typed_data 1.3.0 [collection]
- vector_math 2.1.0
- xml 5.1.0 [collection meta petitparser]
- yaml 3.1.0 [collection source_span string_scanner]
` |
This seems like a pretty obscure error so not sure what exactly could be causing it at a glance. Could you try to see if the same issue persists on the latest version Also it's unclear from the example you provided what part exactly could be causing the issue here. It would be really helpful if you could isolate the problem to just |
I have tried using cloud_firestore ^1.0.6 and firebase_core: ^1.0.4 now. The error is still there, even when using those two packages only. Here is the main.dart to test -
|
Tried the provided code but didn't see a crash with firebase_core: ^1.1.0
cloud_firestore: ^1.0.7
flutter doctor -v
|
Hi @CEO-CGS could you please share more details, for example the package.lock file in your project. Also, please share a few details on how the problem can be reproduced. I will try to look at the issues using the FIXED versions specified above, first; but obviously want to avoid double work. |
hi @CEO-CGS I was not able to reproduce this error at all. Please find the sample project here: https://github.com/ened/flutterfire_5856 If you can modify it to crash, then we can take another detail look, else voting to close this ticket. |
Hello. I download and tried running the sample project provided. In my case it did crash. I went through the following steps before running the project though: I updated the signing section in Xcode, I changed the bundle id and google-services-info.plist file. I did flutter upgrade, pod repo update, pod update, edited the build targets and then I ran it. This is the error that shows up. (Maybe it is slightly different than before?)
|
I also recently installed the most recent stable version of Xcode, and @markusaksli-nc, I tried running the sample project provided by @ened with the updated packages you provided but I received this error - |
@CEO-CGS seems to load just fine here:
Could you give it a go to adjust the pubspec dependencies
Maybe remove firebase_core (comes through cloud_firestore) and use |
I tried removing firebase_core and used cloud_firestore 1.0.7, and did the steps, and I got another type of error... Here is a link to the entire 'build failed' message. I'm not too sure what the error here is - https://docs.google.com/document/d/1YuJSiwiIlfnk53EL9Km4ORgxWl4SUYi-oSKkryv-skE/edit?usp=sharing |
@CEO-CGS very strange - the error points to outdated cocoapods dependencies still. I have upgraded Once pulled, please run |
@ened, unfortunately, this does not seem to fix it either. I went through all the steps provided, and here is the link to the full error message. I think it might be the same one, or similar - https://docs.google.com/document/d/1_IQKUjiilLzRRB9s1ZL6kwu0-7-Sz0hDXHyI5WOwpbw/edit?usp=sharing |
Can you try to remove your pods cache: |
Hey @ened. Here are the results. https://docs.google.com/document/d/1ZV5lYJvb0RNha9zpSe2KkUVp0V52wxrXyeh1FXdPvj0/edit?usp=sharing Sadly, it still did not work. Please check my commands on the doc to see if I made the wrong commands and the full output. |
Any solution yet? |
Anything new anyone? Still hoping to use Firebase in one of my flutter projects.... |
@CEO-CGS, Have you tried on a completely fresh application? By the way, the error suggests to me that you're initialising Firebase twice. So maybe double check you aren't initialising in your Swift code and Dart. |
Closing due to inactivity. |
So, I've done lots of researching across the internet, have tried all the solutions I could think off:
flutter clean
,pod init, pod install pod update
, updating the security rules, and also re-adding the Google Services plist file multiple times through Xcode, editing AppDelegate.swift and adding the proper code, making sure to ensurewidgetbinding and initializing the FirebaseApp in main, updating my firebase packages, but this error still keeps popping up when trying to access Firestore data. Firestore auth works fine though, and although my app doesn't work on a iOS simulator, it works perfectly find on Android simulator.I've been facing this issue for a number of days now.
The key issue is: *** Terminating app due to uncaught exception 'NSInternalInconsistencyException', reason: 'FIRESTORE INTERNAL ASSERTION FAILED: threads > 1'
Here are more details of the stack log:
Here is my flutter doctor -v results as well if needed:
Here is the code sample I try to run -
Wrapper class -
The text was updated successfully, but these errors were encountered: