Skip to content

🐛 [firebase_storage] invokeMethod called after shutdown  #8919

Closed

Description

@rmtmckenzie

Bug report

Describe the bug

During app shutdown, there seems to be a condition where a FIRStorageTaskStatus changes after the engine has been disconnected. This is causing an error to be reported: Fatal Exception: NSInternalInconsistencyException Sending a message before the FlutterEngine has been run..

The error in firebase is as follows:

FLTFirebaseStoragePlugin.m line 580
__100-[FLTFirebaseStoragePlugin startFIRStorageObservableTaskForArguments:andFLTFirebaseStorageTaskType:]_block_invoke_2.536

It appears that some cleanup is being done upon the engine being disconnected, but that it doesn't stop the method from being called in all cases.

I've only seen the error in production as it seems like it might be due to some sort of race condition. It's not happening enough to be a huge deal yet and seems to be only during shutdown, but it's still getting reported to apple and affecting crash rates.

Steps to reproduce

Unfortunately, I've not been able to reproduce this reliably.

Expected behavior

No channel.invokeMethod call should be made after the engine has been disconnected.

Sample project

N/A


Additional context

Stacktrace from crashlytics:

Click To Expand

Fatal Exception: NSInternalInconsistencyException
0 CoreFoundation 0x99288 __exceptionPreprocess
1 libobjc.A.dylib 0x16744 objc_exception_throw
2 Foundation 0x132360 _userInfoForFileAndLine
3 Flutter 0x1256c (Missing UUID bab62788d88339b192aed18e13dece71)
4 Runner 0x42ce10 __100-[FLTFirebaseStoragePlugin startFIRStorageObservableTaskForArguments:andFLTFirebaseStorageTaskType:]_block_invoke_2.536 + 580 (FLTFirebaseStoragePlugin.m:580)
5 libdispatch.dylib 0x1e6c _dispatch_call_block_and_release
6 libdispatch.dylib 0x3a30 _dispatch_client_callout
7 libdispatch.dylib 0xb124 _dispatch_lane_serial_drain
8 libdispatch.dylib 0xbc80 _dispatch_lane_invoke
9 libdispatch.dylib 0x16500 _dispatch_workloop_worker_thread
10 libsystem_pthread.dylib 0x10bc _pthread_wqthread
11 libsystem_pthread.dylib 0xe5c start_wqthread


Flutter doctor

Run flutter doctor and paste the output below:

Click To Expand
Doctor summary (to see all details, run flutter doctor -v):
[✓] Flutter (Channel stable, 3.0.2, on macOS 12.4 21F79 darwin-x64, locale en-CA)
[✓] Android toolchain - develop for Android devices (Android SDK version 33.0.0-rc2)
[✓] Xcode - develop for iOS and macOS (Xcode 13.4.1)
[✓] Chrome - develop for the web
[✓] Android Studio (version 2021.2)
[✓] IntelliJ IDEA Community Edition (version 2021.2.4)
[✓] VS Code (version 1.68.0)
[✓] Connected device (4 available)
    ! Error: MiPhone is busy: Fetching debug symbols for MiPhone. Xcode will continue when MiPhone is finished. (code -10)
[✓] HTTP Host Availability

• No issues found!


Flutter dependencies

Run flutter pub deps -- --style=compact and paste the output below:

Click To Expand
Dart SDK 2.17.3
Flutter SDK 3.0.2
rootd_flutter 2.4.43+232

dependencies:
- adjust_sdk 4.30.0 [flutter meta]
- app_settings 4.1.8 [flutter]
- auto_size_text 3.0.0-nullsafety.0 [flutter]
- bubble 1.2.1 [flutter]
- cloud_firestore 3.1.17 [cloud_firestore_platform_interface cloud_firestore_web collection firebase_core firebase_core_platform_interface flutter meta]
- cloud_functions 3.2.16 [cloud_functions_platform_interface cloud_functions_web firebase_core firebase_core_platform_interface flutter]
- collection 1.16.0
- connectivity_plus 2.3.5 [flutter connectivity_plus_platform_interface connectivity_plus_linux connectivity_plus_macos connectivity_plus_web connectivity_plus_windows]
- cupertino_icons 1.0.5
- device_calendar 4.2.0 [flutter collection sprintf timezone flutter_native_timezone]
- facebook_app_events 0.16.0 [flutter]
- firebase_analytics 9.1.9 [firebase_analytics_platform_interface firebase_analytics_web firebase_core firebase_core_platform_interface flutter]
- firebase_app_installations 0.1.0+14 [firebase_app_installations_platform_interface firebase_app_installations_web firebase_core firebase_core_platform_interface flutter]
- firebase_auth 3.3.19 [firebase_auth_platform_interface firebase_auth_web firebase_core firebase_core_platform_interface flutter meta]
- firebase_core 1.17.1 [firebase_core_platform_interface firebase_core_web flutter meta]
- firebase_crashlytics 2.8.1 [firebase_core firebase_core_platform_interface firebase_crashlytics_platform_interface flutter stack_trace]
- firebase_dynamic_links 4.2.5 [firebase_core firebase_core_platform_interface firebase_dynamic_links_platform_interface flutter meta plugin_platform_interface]
- firebase_messaging 11.4.1 [firebase_core firebase_core_platform_interface firebase_messaging_platform_interface firebase_messaging_web flutter meta]
- firebase_remote_config 2.0.8 [firebase_core firebase_core_platform_interface firebase_remote_config_platform_interface firebase_remote_config_web flutter]
- firebase_storage 10.2.17 [firebase_core firebase_core_platform_interface firebase_storage_platform_interface firebase_storage_web flutter]
- fl_chart 0.46.0 [flutter equatable]
- flutter 0.0.0 [characters collection material_color_utilities meta vector_math sky_engine]
- flutter_email_sender 5.1.0 [flutter]
- flutter_local_notifications 9.6.0 [clock flutter flutter_local_notifications_linux flutter_local_notifications_platform_interface timezone]
- flutter_localizations 0.0.0 [flutter intl characters clock collection material_color_utilities meta path vector_math]
- flutter_native_timezone 2.0.0 [flutter_web_plugins flutter js]
- flutter_platform_widgets 2.0.0 [flutter]
- flutter_svg 1.0.3 [flutter meta path_drawing vector_math xml]
- form_field_validator 1.1.0 [flutter intl]
- google_sign_in 5.3.3 [flutter google_sign_in_android google_sign_in_ios google_sign_in_platform_interface google_sign_in_web]
- image_picker 0.8.5+3 [flutter image_picker_android image_picker_for_web image_picker_ios image_picker_platform_interface]
- in_app_review 2.0.4 [flutter in_app_review_platform_interface]
- intl 0.17.0 [clock path]
- jiffy 5.0.0 [intl]
- json_annotation 4.5.0 [meta]
- just_audio 0.9.24 [just_audio_platform_interface just_audio_web audio_session rxdart path path_provider async uuid crypto meta flutter]
- just_audio_background 0.0.1-beta.5 [just_audio_platform_interface audio_service audio_session flutter flutter_web_plugins meta rxdart]
- lottie 1.3.0 [archive flutter path vector_math]
- mailto 2.0.0
- objectbox 1.5.0 [collection flat_buffers ffi meta path]
- objectbox_flutter_libs 1.5.0 [objectbox path_provider]
- package_info_plus 1.4.2 [flutter package_info_plus_platform_interface package_info_plus_linux package_info_plus_macos package_info_plus_windows package_info_plus_web]
- path 1.8.1
- path_provider 2.0.11 [flutter path_provider_android path_provider_ios path_provider_linux path_provider_macos path_provider_platform_interface path_provider_windows]
- permission_handler 9.2.0 [flutter meta permission_handler_android permission_handler_apple permission_handler_windows permission_handler_platform_interface]
- purchases_flutter 3.10.0 [flutter freezed_annotation json_annotation]
- quiver 3.1.0 [matcher]
- random_string 2.3.1
- scoped_model 2.0.0-nullsafety.0 [flutter]
- share_plus 4.0.7 [meta mime flutter share_plus_platform_interface share_plus_linux share_plus_macos share_plus_windows share_plus_web]
- shared_preferences 2.0.15 [flutter shared_preferences_android shared_preferences_ios shared_preferences_linux shared_preferences_macos shared_preferences_platform_interface shared_preferences_web shared_preferences_windows]
- sign_in_with_apple 4.0.0 [flutter meta sign_in_with_apple_platform_interface sign_in_with_apple_web]
- smooth_page_indicator 1.0.0+2 [flutter]
- speech_to_text 5.5.0 [flutter speech_to_text_platform_interface json_annotation clock pedantic flutter_web_plugins meta js]
- stack_trace 1.10.0 [path]
- styled_text 5.1.0 [flutter xmlstream]
- super_tooltip 1.0.1 [flutter]
- table_calendar 3.0.6 [flutter intl simple_gesture_detector]
- toast 0.2.0-nullsafety [flutter]
- uni_links 0.5.1 [flutter uni_links_platform_interface uni_links_web]
- url_launcher 6.1.3 [flutter url_launcher_android url_launcher_ios url_launcher_linux url_launcher_macos url_launcher_platform_interface url_launcher_web url_launcher_windows]
- vibration 1.7.4-nullsafety.0 [flutter vibration_web]
- wakelock 0.6.1+2 [flutter meta wakelock_macos wakelock_platform_interface wakelock_web wakelock_windows]

dev dependencies:
- build_runner 2.1.11 [args async analyzer build build_config build_daemon build_resolvers build_runner_core code_builder collection crypto dart_style frontend_server_client glob graphs http_multi_server io js logging meta mime package_config path pool pub_semver pubspec_parse shelf shelf_web_socket stack_trace stream_transform timing watcher web_socket_channel yaml]
- flutter_lints 1.0.4 [lints]
- flutter_test 0.0.0 [flutter test_api path fake_async clock stack_trace vector_math async boolean_selector characters charcode collection matcher material_color_utilities meta source_span stream_channel string_scanner term_glyph]
- intl_utils 2.6.1 [analyzer archive args dart_style http intl path petitparser yaml]
- json_serializable 6.2.0 [analyzer async build build_config collection json_annotation meta path pub_semver pubspec_parse source_gen source_helper]
- objectbox_generator 1.5.0 [objectbox analyzer build collection dart_style glob path source_gen pubspec_parse yaml]

dependency overrides:
- auto_size_text 3.0.0-nullsafety.0 [flutter]
- connectivity_plus 2.3.5 [flutter connectivity_plus_platform_interface connectivity_plus_linux connectivity_plus_macos connectivity_plus_web connectivity_plus_windows]
- connectivity_plus_macos 1.2.4 [connectivity_plus_platform_interface flutter]
- flutter_native_screenshot 1.1.2 [flutter]
- toast 0.2.0-nullsafety [flutter]
- uni_links_platform_interface 1.0.0 [flutter plugin_platform_interface]
- uni_links_web 0.1.0 [flutter flutter_web_plugins uni_links_platform_interface]
- vibration 1.7.4-nullsafety.0 [flutter vibration_web]

transitive dependencies:
- _fe_analyzer_shared 38.0.0 [meta]
- analyzer 3.4.1 [_fe_analyzer_shared collection convert crypto glob meta package_config path pub_semver source_span watcher yaml]
- archive 3.3.0 [crypto path]
- args 2.3.1
- async 2.8.2 [collection meta]
- audio_service 0.18.4 [audio_service_platform_interface audio_service_web audio_session rxdart flutter_cache_manager clock js flutter flutter_web_plugins]
- audio_service_platform_interface 0.1.0 [flutter plugin_platform_interface meta]
- audio_service_web 0.1.1 [audio_service_platform_interface rxdart js flutter flutter_web_plugins]
- audio_session 0.1.7 [flutter flutter_web_plugins rxdart meta]
- boolean_selector 2.1.0 [source_span string_scanner]
- build 2.3.0 [analyzer async convert crypto glob logging meta path]
- build_config 1.0.0 [checked_yaml json_annotation path pubspec_parse yaml]
- build_daemon 3.1.0 [built_collection built_value http_multi_server logging path pool shelf shelf_web_socket stream_transform watcher web_socket_channel]
- build_resolvers 2.0.9 [analyzer async build crypto graphs logging path package_config pool pub_semver stream_transform yaml]
- build_runner_core 7.2.3 [async build build_config build_resolvers collection convert crypto glob graphs json_annotation logging meta path package_config pool timing watcher yaml]
- built_collection 5.1.1
- built_value 8.3.2 [built_collection collection fixnum meta]
- characters 1.2.0
- charcode 1.3.1
- checked_yaml 2.0.1 [json_annotation source_span yaml]
- clock 1.1.0
- cloud_firestore_platform_interface 5.5.7 [collection firebase_core flutter meta plugin_platform_interface]
- cloud_firestore_web 2.6.16 [cloud_firestore_platform_interface collection firebase_core firebase_core_web flutter flutter_web_plugins js]
- cloud_functions_platform_interface 5.1.7 [firebase_core flutter meta plugin_platform_interface]
- cloud_functions_web 4.2.15 [cloud_functions_platform_interface firebase_core firebase_core_web flutter flutter_web_plugins js]
- code_builder 4.1.0 [built_collection built_value collection matcher meta]
- connectivity_plus_linux 1.3.1 [flutter connectivity_plus_platform_interface meta nm]
- connectivity_plus_platform_interface 1.2.1 [flutter meta plugin_platform_interface]
- connectivity_plus_web 1.2.2 [connectivity_plus_platform_interface flutter_web_plugins flutter]
- connectivity_plus_windows 1.2.2 [connectivity_plus_platform_interface flutter]
- convert 3.0.2 [typed_data]
- cross_file 0.3.3+1 [js meta]
- crypto 3.0.2 [typed_data]
- dart_style 2.2.3 [analyzer args path pub_semver source_span]
- dbus 0.7.3 [args ffi meta xml]
- equatable 2.0.3 [collection meta]
- fake_async 1.3.0 [clock collection]
- ffi 1.2.1
- file 6.1.2 [meta path]
- firebase_analytics_platform_interface 3.1.7 [firebase_core flutter meta plugin_platform_interface]
- firebase_analytics_web 0.4.0+14 [firebase_analytics_platform_interface firebase_core firebase_core_web flutter flutter_web_plugins js]
- firebase_app_installations_platform_interface 0.1.1+7 [firebase_core flutter meta plugin_platform_interface]
- firebase_app_installations_web 0.1.0+14 [firebase_app_installations_platform_interface firebase_core firebase_core_web flutter flutter_web_plugins js]
- firebase_auth_platform_interface 6.2.7 [firebase_core flutter meta plugin_platform_interface]
- firebase_auth_web 3.3.16 [firebase_auth_platform_interface firebase_core firebase_core_web flutter flutter_web_plugins http_parser intl js meta]
- firebase_core_platform_interface 4.4.0 [collection flutter meta plugin_platform_interface]
- firebase_core_web 1.6.4 [firebase_core_platform_interface flutter flutter_web_plugins js meta]
- firebase_crashlytics_platform_interface 3.2.7 [collection firebase_core flutter meta plugin_platform_interface]
- firebase_dynamic_links_platform_interface 0.2.3+3 [firebase_core flutter meta plugin_platform_interface]
- firebase_messaging_platform_interface 3.5.1 [firebase_core flutter meta plugin_platform_interface]
- firebase_messaging_web 2.4.1 [firebase_core firebase_core_web firebase_messaging_platform_interface flutter flutter_web_plugins js meta]
- firebase_remote_config_platform_interface 1.1.7 [firebase_core flutter meta plugin_platform_interface]
- firebase_remote_config_web 1.0.13 [firebase_core firebase_core_web firebase_remote_config_platform_interface flutter flutter_web_plugins js]
- firebase_storage_platform_interface 4.1.7 [collection firebase_core flutter meta plugin_platform_interface]
- firebase_storage_web 3.2.16 [async firebase_core firebase_core_web firebase_storage_platform_interface flutter flutter_web_plugins http js meta]
- fixnum 1.0.1
- flat_buffers 2.0.5
- flutter_cache_manager 3.3.0 [clock collection file flutter http path path_provider pedantic rxdart sqflite uuid]
- flutter_local_notifications_linux 0.5.0+1 [flutter flutter_local_notifications_platform_interface dbus path xdg_directories]
- flutter_local_notifications_platform_interface 5.0.0 [flutter plugin_platform_interface]
- flutter_plugin_android_lifecycle 2.0.6 [flutter]
- flutter_web_plugins 0.0.0 [flutter js characters collection material_color_utilities meta vector_math]
- freezed_annotation 1.1.0 [collection json_annotation meta]
- frontend_server_client 2.1.3 [async path]
- glob 2.0.2 [async collection file path string_scanner]
- google_sign_in_android 5.2.8 [flutter google_sign_in_platform_interface]
- google_sign_in_ios 5.3.1 [flutter google_sign_in_platform_interface]
- google_sign_in_platform_interface 2.1.3 [flutter quiver]
- google_sign_in_web 0.10.1+3 [flutter flutter_web_plugins google_sign_in_platform_interface js]
- graphs 2.1.0 [collection]
- http 0.13.4 [async http_parser meta path]
- http_multi_server 3.2.0 [async]
- http_parser 4.0.1 [collection source_span string_scanner typed_data]
- image_picker_android 0.8.5 [flutter flutter_plugin_android_lifecycle image_picker_platform_interface]
- image_picker_for_web 2.1.8 [flutter flutter_web_plugins image_picker_platform_interface]
- image_picker_ios 0.8.5+5 [flutter image_picker_platform_interface]
- image_picker_platform_interface 2.5.0 [cross_file flutter http plugin_platform_interface]
- in_app_review_platform_interface 2.0.3 [flutter url_launcher plugin_platform_interface platform]
- io 1.0.3 [meta path string_scanner]
- js 0.6.4
- just_audio_platform_interface 4.1.0 [flutter plugin_platform_interface]
- just_audio_web 0.4.7 [just_audio_platform_interface flutter flutter_web_plugins]
- lints 1.0.1
- logging 1.0.2
- matcher 0.12.11 [stack_trace]
- material_color_utilities 0.1.4
- meta 1.7.0
- mime 1.0.2
- nm 0.5.0 [dbus]
- package_config 2.0.2 [path]
- package_info_plus_linux 1.0.5 [package_info_plus_platform_interface flutter path]
- package_info_plus_macos 1.3.0 [flutter]
- package_info_plus_platform_interface 1.0.2 [flutter meta plugin_platform_interface]
- package_info_plus_web 1.0.5 [flutter flutter_web_plugins http meta package_info_plus_platform_interface]
- package_info_plus_windows 1.0.5 [package_info_plus_platform_interface ffi flutter win32]
- path_drawing 1.0.0 [vector_math meta path_parsing flutter]
- path_parsing 1.0.0 [vector_math meta]
- path_provider_android 2.0.14 [flutter path_provider_platform_interface]
- path_provider_ios 2.0.9 [flutter path_provider_platform_interface]
- path_provider_linux 2.1.7 [ffi flutter path path_provider_platform_interface xdg_directories]
- path_provider_macos 2.0.6 [flutter path_provider_platform_interface]
- path_provider_platform_interface 2.0.4 [flutter platform plugin_platform_interface]
- path_provider_windows 2.0.7 [ffi flutter path path_provider_platform_interface win32]
- pedantic 1.11.1
- permission_handler_android 9.0.2+1 [flutter permission_handler_platform_interface]
- permission_handler_apple 9.0.4 [flutter permission_handler_platform_interface]
- permission_handler_platform_interface 3.7.0 [flutter meta plugin_platform_interface]
- permission_handler_windows 0.1.0 [flutter permission_handler_platform_interface]
- petitparser 4.4.0 [meta]
- platform 3.1.0
- plugin_platform_interface 2.1.2 [meta]
- pool 1.5.0 [async stack_trace]
- process 4.2.4 [file path platform]
- pub_semver 2.1.1 [collection meta]
- pubspec_parse 1.2.0 [checked_yaml collection json_annotation pub_semver yaml]
- rxdart 0.27.4
- share_plus_linux 3.0.0 [share_plus_platform_interface file flutter meta url_launcher]
- share_plus_macos 3.0.1 [share_plus_platform_interface flutter]
- share_plus_platform_interface 3.0.3 [flutter meta mime plugin_platform_interface]
- share_plus_web 3.0.1 [share_plus_platform_interface url_launcher flutter flutter_web_plugins meta]
- share_plus_windows 3.0.1 [share_plus_platform_interface flutter meta url_launcher]
- shared_preferences_android 2.0.12 [flutter shared_preferences_platform_interface]
- shared_preferences_ios 2.1.1 [flutter shared_preferences_platform_interface]
- shared_preferences_linux 2.1.1 [file flutter path path_provider_linux path_provider_platform_interface shared_preferences_platform_interface]
- shared_preferences_macos 2.0.4 [flutter shared_preferences_platform_interface]
- shared_preferences_platform_interface 2.0.0 [flutter]
- shared_preferences_web 2.0.4 [flutter flutter_web_plugins shared_preferences_platform_interface]
- shared_preferences_windows 2.1.1 [file flutter path path_provider_platform_interface path_provider_windows shared_preferences_platform_interface]
- shelf 1.3.0 [async collection http_parser path stack_trace stream_channel]
- shelf_web_socket 1.0.1 [shelf stream_channel web_socket_channel]
- sign_in_with_apple_platform_interface 1.0.0 [flutter plugin_platform_interface meta]
- sign_in_with_apple_web 1.0.1 [flutter flutter_web_plugins sign_in_with_apple_platform_interface js]
- simple_gesture_detector 0.2.0 [flutter]
- sky_engine 0.0.99
- source_gen 1.2.2 [analyzer async build dart_style glob meta path source_span yaml]
- source_helper 1.3.2 [analyzer collection source_gen]
- source_span 1.8.2 [collection path term_glyph]
- speech_to_text_platform_interface 2.0.1 [flutter meta plugin_platform_interface]
- sprintf 6.0.0
- sqflite 2.0.2+1 [flutter sqflite_common path]
- sqflite_common 2.2.1+1 [synchronized path meta]
- stream_channel 2.1.0 [async]
- stream_transform 2.0.0
- string_scanner 1.1.0 [charcode source_span]
- synchronized 3.0.0+2
- term_glyph 1.2.0
- test_api 0.4.9 [async boolean_selector collection meta source_span stack_trace stream_channel string_scanner term_glyph matcher]
- timezone 0.8.0 [path]
- timing 1.0.0 [json_annotation]
- typed_data 1.3.1 [collection]
- url_launcher_android 6.0.17 [flutter url_launcher_platform_interface]
- url_launcher_ios 6.0.17 [flutter url_launcher_platform_interface]
- url_launcher_linux 3.0.1 [flutter url_launcher_platform_interface]
- url_launcher_macos 3.0.1 [flutter url_launcher_platform_interface]
- url_launcher_platform_interface 2.0.5 [flutter plugin_platform_interface]
- url_launcher_web 2.0.11 [flutter flutter_web_plugins url_launcher_platform_interface]
- url_launcher_windows 3.0.1 [flutter url_launcher_platform_interface]
- uuid 3.0.6 [crypto]
- vector_math 2.1.2
- vibration_web 1.6.3-nullsafety.0 [flutter flutter_web_plugins]
- wakelock_macos 0.4.0 [flutter flutter_web_plugins wakelock_platform_interface]
- wakelock_platform_interface 0.3.0 [flutter meta]
- wakelock_web 0.4.0 [flutter flutter_web_plugins js wakelock_platform_interface]
- wakelock_windows 0.2.0 [flutter wakelock_platform_interface win32]
- watcher 1.0.1 [async path]
- web_socket_channel 2.2.0 [async crypto stream_channel]
- win32 2.6.1 [ffi]
- xdg_directories 0.2.0+1 [meta path process]
- xml 5.3.1 [collection meta petitparser]
- xmlstream 1.0.0
- yaml 3.1.1 [collection source_span string_scanner]


Activity

  1. added
    Needs Attention
    type: bug
    on Jun 16, 2022
  2. added
    triage
    on Jun 16, 2022
  3. maheshj01 commented on Jun 16, 2022

    @maheshj01
    Contributor

    Hi @rmtmckenzie, Thanks for reporting the issue. Since this issue occurs in production and there aren't any reproducible steps. I won't be able to investigate this issue further. Labeling this issue for further investigation from the team.

    Thank you.

  4. added
    type: crash
    and removed
    Needs Attention
    triage
    on Jun 16, 2022
  5. rmtmckenzie commented on Jun 16, 2022

    @rmtmckenzie
    ContributorAuthor

    Fair enough - I think it's a bit of a tricky one, otherwise I would have tried to do a PR myself. And thanks @maheshmnj for the quick response in looking at it =).

  6. Ali1Ammar commented on Oct 22, 2022

    @Ali1Ammar

    I have the same bugs recently in a new version of my app and the only edit I made related to firebase storage is using writeToFile methods (before I was using getDownloadURL with dio to download the file)
    I do not know if it is related to this bugs but it may help founding the issues

     FLTFirebaseStoragePlugin.m line 580
    __100-[FLTFirebaseStoragePlugin startFIRStorageObservableTaskForArguments:andFLTFirebaseStorageTaskType:]_block_invoke_2.518 
    
    Sending a message before the FlutterEngine has been run.
    Fatal Exception: NSInternalInconsistencyException
    0  CoreFoundation                 0xa248 __exceptionPreprocess
    1  libobjc.A.dylib                0x17a68 objc_exception_throw
    2  Foundation                     0x54681c _userInfoForFileAndLine
    3  Flutter                        0x12fe0 (Missing UUID 8737ebfeefcd30f784da3fdc268b8534)
    4  Runner                         0x2fab50 __100-[FLTFirebaseStoragePlugin startFIRStorageObservableTaskForArguments:andFLTFirebaseStorageTaskType:]_block_invoke_2.518 + 580 (FLTFirebaseStoragePlugin.m:580)
    5  libdispatch.dylib              0x24b4 _dispatch_call_block_and_release
    6  libdispatch.dylib              0x3fdc _dispatch_client_callout
    7  libdispatch.dylib              0xb694 _dispatch_lane_serial_drain
    8  libdispatch.dylib              0xc1e0 _dispatch_lane_invoke
    9  libdispatch.dylib              0x16e10 _dispatch_workloop_worker_thread
    10 libsystem_pthread.dylib        0xdf8 _pthread_wqthread
    11 libsystem_pthread.dylib        0xb98 start_wqthread
    
    
    Crashed: com.google.firebase.crashlytics.ios.exception
    0  FirebaseCrashlytics            0x222ec FIRCLSProcessRecordAllThreads + 184
    1  FirebaseCrashlytics            0x226cc FIRCLSProcessRecordAllThreads + 1176
    2  FirebaseCrashlytics            0x1869c FIRCLSHandler + 48
    3  FirebaseCrashlytics            0x128c4 __FIRCLSExceptionRecord_block_invoke + 92
    4  libdispatch.dylib              0x3fdc _dispatch_client_callout + 20
    5  libdispatch.dylib              0x13574 _dispatch_lane_barrier_sync_invoke_and_complete + 56
    6  FirebaseCrashlytics            0x116a4 FIRCLSExceptionRecord + 204
    7  FirebaseCrashlytics            0x1236c FIRCLSExceptionRecordNSException + 556
    8  FirebaseCrashlytics            0x112a4 FIRCLSTerminateHandler() + 404
    9  libc++abi.dylib                0x10f28 std::__terminate(void (*)()) + 20
    10 libc++abi.dylib                0x10ec4 std::terminate() + 56
    11 libobjc.A.dylib                0x339ec objc_terminate + 16
    12 libdispatch.dylib              0x3ff0 _dispatch_client_callout + 40
    13 libdispatch.dylib              0xb694 _dispatch_lane_serial_drain + 672
    14 libdispatch.dylib              0xc1e0 _dispatch_lane_invoke + 384
    15 libdispatch.dylib              0x16e10 _dispatch_workloop_worker_thread + 652
    16 libsystem_pthread.dylib        0xdf8 _pthread_wqthread + 288
    17 libsystem_pthread.dylib        0xb98 start_wqthread + 8
    
  7. jamesdixon commented on Nov 23, 2022

    @jamesdixon

    We're also seeing this one in production on occasion.

  8. tatraef commented on Dec 22, 2022

    @tatraef

    I also get this crash in release

    Logs
    Fatal Exception: NSInternalInconsistencyException
    0  CoreFoundation                 0x9a84 __exceptionPreprocess
    1  libobjc.A.dylib                0x15958 objc_exception_throw
    2  Foundation                     0x4bf130 _userInfoForFileAndLine
    3  Flutter                        0x12bac (Missing UUID 3adbf2891ee63561a26df1652313df7e)
    4  sensors_plus                   0x692c (Missing UUID 3aefceb28c3a34baba95bffdbed20516)
    5  Foundation                     0x9d3c4 __NSBLOCKOPERATION_IS_CALLING_OUT_TO_A_BLOCK__
    6  Foundation                     0x740fc -[NSBlockOperation main]
    7  Foundation                     0x74090 __NSOPERATION_IS_INVOKING_MAIN__
    8  Foundation                     0x38ef4 -[NSOperation start]
    9  Foundation                     0x38c40 __NSOPERATIONQUEUE_IS_STARTING_AN_OPERATION__
    10 Foundation                     0x3dd60 __NSOQSchedule_f
    11 libdispatch.dylib              0x46738 _dispatch_block_async_invoke2
    12 libdispatch.dylib              0x647c8 _dispatch_client_callout
    13 libdispatch.dylib              0x3be7c _dispatch_continuation_pop$VARIANT$armv81
    14 libdispatch.dylib              0x3b5b4 _dispatch_async_redirect_invoke
    15 libdispatch.dylib              0x48d48 _dispatch_root_queue_drain
    16 libdispatch.dylib              0x49514 _dispatch_worker_thread2
    17 libsystem_pthread.dylib        0x1b14 _pthread_wqthread
    18 libsystem_pthread.dylib        0x167c start_wqthread
    
    Crashed: com.google.firebase.crashlytics.ios.exception
    0  FirebaseCrashlytics            0x1eea8 FIRCLSProcessRecordAllThreads + 184
    1  FirebaseCrashlytics            0x1f288 FIRCLSProcessRecordAllThreads + 1176
    2  FirebaseCrashlytics            0x164d4 FIRCLSHandler + 48
    3  FirebaseCrashlytics            0x111a8 __FIRCLSExceptionRecord_block_invoke + 92
    4  libdispatch.dylib              0x647c8 _dispatch_client_callout + 16
    5  libdispatch.dylib              0x46b54 _dispatch_lane_barrier_sync_invoke_and_complete + 52
    6  FirebaseCrashlytics            0x101b4 FIRCLSExceptionRecord + 204
    7  FirebaseCrashlytics            0x10cc8 FIRCLSExceptionRecordNSException + 452
    8  FirebaseCrashlytics            0xfe0c FIRCLSTerminateHandler() + 404
    9  Runner                         0x1ef590 CPPExceptionTerminate() + 528
    10 libc++abi.dylib                0x10288 std::__terminate(void (*)()) + 16
    11 libc++abi.dylib                0x10230 std::terminate() + 52
    12 libobjc.A.dylib                0x2b000 objc_terminate + 12
    13 libdispatch.dylib              0x647dc _dispatch_client_callout + 36
    14 libdispatch.dylib              0x3be7c _dispatch_continuation_pop$VARIANT$armv81 + 436
    15 libdispatch.dylib              0x3b5b4 _dispatch_async_redirect_invoke + 580
    16 libdispatch.dylib              0x48d48 _dispatch_root_queue_drain + 328
    17 libdispatch.dylib              0x49514 _dispatch_worker_thread2 + 160
    18 libsystem_pthread.dylib        0x1b14 _pthread_wqthread + 224
    19 libsystem_pthread.dylib        0x167c start_wqthread + 8
    
    com.apple.main-thread
    0  libsystem_kernel.dylib         0x19e0 __psynch_cvwait + 8
    1  libsystem_pthread.dylib        0x2584 _pthread_cond_wait$VARIANT$armv81 + 1220
    2  libc++.1.dylib                 0xc8b4 std::__1::condition_variable::wait(std::__1::unique_lock<std::__1::mutex>&) + 24
    3  Flutter                        0x2f7768 (Missing UUID 3adbf2891ee63561a26df1652313df7e)
    4  Flutter                        0x3da0f0 (Missing UUID 3adbf2891ee63561a26df1652313df7e)
    5  Flutter                        0x14424 (Missing UUID 3adbf2891ee63561a26df1652313df7e)
    6  Flutter                        0xff90 (Missing UUID 3adbf2891ee63561a26df1652313df7e)
    7  CoreFoundation                 0x34b44 __CFNOTIFICATIONCENTER_IS_CALLING_OUT_TO_AN_OBSERVER__ + 140
    8  CoreFoundation                 0xd40d0 ___CFXRegistrationPost_block_invoke + 84
    9  CoreFoundation                 0xb8b78 _CFXRegistrationPost + 404
    10 CoreFoundation                 0x48308 _CFXNotificationPost + 684
    11 Foundation                     0x574ec -[NSNotificationCenter postNotificationName:object:userInfo:] + 88
    12 UIKitCore                      0xc6ac48 -[UIApplication _terminateWithStatus:] + 228
    13 UIKitCore                      0x270adc -[_UISceneLifecycleMultiplexer _evalTransitionToSettings:fromSettings:forceExit:withTransitionStore:] + 108
    14 UIKitCore                      0x64b9e8 -[_UISceneLifecycleMultiplexer forceExitWithTransitionContext:scene:] + 160
    15 UIKitCore                      0xc67364 -[UIApplication workspaceShouldExit:withTransitionContext:] + 172
    16 FrontBoardServices             0x3b388 __63-[FBSWorkspaceScenesClient willTerminateWithTransitionContext:]_block_invoke_2 + 68
    17 FrontBoardServices             0x5f70 -[FBSWorkspace _calloutQueue_executeCalloutFromSource:withBlock:] + 160
    18 FrontBoardServices             0x3b32c __63-[FBSWorkspaceScenesClient willTerminateWithTransitionContext:]_block_invoke + 96
    19 libdispatch.dylib              0x647c8 _dispatch_client_callout + 16
    20 libdispatch.dylib              0x3c408 _dispatch_block_invoke_direct$VARIANT$armv81 + 212
    21 FrontBoardServices             0xf474 __FBSSERIALQUEUE_IS_CALLING_OUT_TO_A_BLOCK__ + 44
    22 FrontBoardServices             0xf0b0 -[FBSSerialQueue _targetQueue_performNextIfPossible] + 176
    23 FrontBoardServices             0x11574 -[FBSSerialQueue _performNextFromRunLoopSource] + 24
    24 CoreFoundation                 0xcc2b8 __CFRUNLOOP_IS_CALLING_OUT_TO_A_SOURCE0_PERFORM_FUNCTION__ + 24
    25 CoreFoundation                 0xd7c18 __CFRunLoopDoSource0 + 172
    26 CoreFoundation                 0x61fa8 __CFRunLoopDoSources0 + 232
    27 CoreFoundation                 0x76fb0 __CFRunLoopRun + 780
    28 CoreFoundation                 0x7bb7c CFRunLoopRunSpecific + 584
    29 GraphicsServices               0x1984 GSEventRunModal + 160
    30 UIKitCore                      0x3753c8 -[UIApplication _run] + 868
    31 UIKitCore                      0x375040 UIApplicationMain + 312
    32 Runner                         0x5654 main + 9 (AppDelegate.swift:9)
    33 ???                            0x1a67dcdf0 (Missing)
    
    com.apple.uikit.eventfetch-thread
    0  libsystem_kernel.dylib         0x1194 mach_msg2_trap + 8
    1  libsystem_kernel.dylib         0x12a08 mach_msg2_internal + 76
    2  libsystem_kernel.dylib         0x12c44 mach_msg_overwrite + 384
    3  libsystem_kernel.dylib         0x1688 mach_msg + 20
    4  CoreFoundation                 0x75fc4 __CFRunLoopServiceMachPort + 156
    5  CoreFoundation                 0x77174 __CFRunLoopRun + 1232
    6  CoreFoundation                 0x7bb7c CFRunLoopRunSpecific + 584
    7  Foundation                     0x3e428 -[NSRunLoop(NSRunLoop) runMode:beforeDate:] + 208
    8  Foundation                     0x3e324 -[NSRunLoop(NSRunLoop) runUntilDate:] + 60
    9  UIKitCore                      0x49a0e0 -[UIEventFetcher threadMain] + 424
    10 Foundation                     0x55f74 __NSThread__start__ + 704
    11 libsystem_pthread.dylib        0x3060 _pthread_start + 116
    12 libsystem_pthread.dylib        0x1688 thread_start + 8
    
    io.flutter.1.ui
    0  libsystem_kernel.dylib         0x19b8 posix_madvise + 8
    1  libsystem_kernel.dylib         0x19b8 madvise + 8
    2  libsystem_malloc.dylib         0x574c mvm_madvise_free + 132
    3  libsystem_malloc.dylib         0x6168 small_madvise_free_range_no_lock + 488
    4  libsystem_malloc.dylib         0x70e0 free_small + 816
    5  Flutter                        0x477024 (Missing UUID 3adbf2891ee63561a26df1652313df7e)
    6  Flutter                        0x47dc98 (Missing UUID 3adbf2891ee63561a26df1652313df7e)
    7  Flutter                        0x4796d4 (Missing UUID 3adbf2891ee63561a26df1652313df7e)
    8  Flutter                        0x41991c (Missing UUID 3adbf2891ee63561a26df1652313df7e)
    9  Flutter                        0x418764 (Missing UUID 3adbf2891ee63561a26df1652313df7e)
    10 Flutter                        0x4d821c (Missing UUID 3adbf2891ee63561a26df1652313df7e)
    11 Flutter                        0x5c7fa4 (Missing UUID 3adbf2891ee63561a26df1652313df7e)
    12 Flutter                        0x5c7d18 (Missing UUID 3adbf2891ee63561a26df1652313df7e)
    13 Flutter                        0x5c88dc (Missing UUID 3adbf2891ee63561a26df1652313df7e)
    14 Flutter                        0x6aa658 (Missing UUID 3adbf2891ee63561a26df1652313df7e)
    15 Flutter                        0x573890 (Missing UUID 3adbf2891ee63561a26df1652313df7e)
    16 Flutter                        0x5732fc (Missing UUID 3adbf2891ee63561a26df1652313df7e)
    17 Flutter                        0x3cc4a4 (Missing UUID 3adbf2891ee63561a26df1652313df7e)
    18 Flutter                        0x3da7a0 (Missing UUID 3adbf2891ee63561a26df1652313df7e)
    19 Flutter                        0x3dafcc (Missing UUID 3adbf2891ee63561a26df1652313df7e)
    20 Flutter                        0x2f5ec4 (Missing UUID 3adbf2891ee63561a26df1652313df7e)
    21 Flutter                        0x2f91fc (Missing UUID 3adbf2891ee63561a26df1652313df7e)
    22 CoreFoundation                 0xc4c9c __CFRUNLOOP_IS_CALLING_OUT_TO_A_TIMER_CALLBACK_FUNCTION__ + 28
    23 CoreFoundation                 0x84c2c __CFRunLoopDoTimer + 884
    24 CoreFoundation                 0x2c450 __CFRunLoopDoTimers + 284
    25 CoreFoundation                 0x77444 __CFRunLoopRun + 1952
    26 CoreFoundation                 0x7bb7c CFRunLoopRunSpecific + 584
    27 Flutter                        0x2f90cc (Missing UUID 3adbf2891ee63561a26df1652313df7e)
    28 Flutter                        0x2f8acc (Missing UUID 3adbf2891ee63561a26df1652313df7e)
    29 libsystem_pthread.dylib        0x3060 _pthread_start + 116
    30 libsystem_pthread.dylib        0x1688 thread_start + 8
    
    [✓] Flutter (Channel stable, 3.3.10, on macOS 13.0 22A380 darwin-arm, locale ru-RU)
    [✓] Android toolchain - develop for Android devices (Android SDK version 32.1.0-rc1)
    [✓] Xcode - develop for iOS and macOS (Xcode 14.0.1)
    [✓] Chrome - develop for the web
    [✓] Android Studio (version 2021.3)
    [✓] VS Code (version 1.74.1)
    [✓] Connected device (3 available)
    [✓] HTTP Host Availability
    
  9. Lyokone commented on Nov 24, 2023

    @Lyokone
    Contributor

    Hi @rmtmckenzie, we have heavily change firebase_storage in the recent versions, do you still see this issue happening? Thanks

  10. added
    blocked: customer-response
    on Nov 24, 2023
  11. rmtmckenzie commented on Nov 26, 2023

    @rmtmckenzie
    ContributorAuthor

    Hey @Lyokone I'm not working on the project that had that issue any more so unfortunately I don't have access to the data to see if it's still happening. Maybe @tatraef or @jamesdixon would be able to comment? If not I'll close this in a couple days.

  12. added
    Needs Attention
    and removed
    blocked: customer-response
    on Nov 26, 2023
  13. added
    blocked: customer-response
    on Jan 4, 2024
  14. added
    Stale
    on Jan 5, 2024
  15. google-oss-bot commented on Jan 5, 2024

    @google-oss-bot
    Collaborator

    Hey @rmtmckenzie. We need more information to resolve this issue but there hasn't been an update in 7 weekdays. I'm marking the issue as stale and if there are no new updates in the next 7 days I will close it automatically.

    If you have more information that will help us get to the bottom of this, just add a comment!

  16. google-oss-bot commented on Jan 16, 2024

    @google-oss-bot
    Collaborator

    Since there haven't been any recent updates here, I am going to close this issue.

    @rmtmckenzie if you're still experiencing this problem and want to continue the discussion just leave a comment here and we are happy to re-open this.

  17. locked and limited conversation to collaborators on Feb 16, 2024
  18. added
    resolution: no-response
    on Apr 16, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    Needs AttentionStaleblocked: customer-responseclosed-by-botplugin: storageresolution: no-responsetype: bugtype: crash

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions