Repository navigation
Closed as duplicate
Labels
c: crashStack traces logged to the consolec: fatal crashCrashes that terminate the processfyi-ecosystemFor the attention of Ecosystem teamp: webviewThe WebView pluginpackageflutter/packages repository. See also p: labels.platform-iosiOS applications specificallyteam-iosOwned by iOS platform team
Description
Steps to reproduce
Unfortunately I am not able to reproduce it. I can only see it happening in my Crashlytics Console.
After upgrading my Flutter version from 3.24.4 to 3.29.2, I start getting this error in my Crashlytics:
Fatal Exception: NSInternalInconsistencyException
Sending a message before the FlutterEngine has been run.
It seems to be happening on random views / actions inside my app. There is no pattern that I can see. The only thing is that it never happened before the upgrade.
I am happy for every help. It's causing our app to lose downloads.
Here is the full stacktrace:
Fatal Exception: NSInternalInconsistencyException
0 CoreFoundation 0x2d5fc __exceptionPreprocess
1 libobjc.A.dylib 0x31244 objc_exception_throw
2 Foundation 0x82dec0 _userInfoForFileAndLine
3 Flutter 0x1fcc4 (Missing UUID 4c4c444355553144a1942736321a049f)
4 Flutter 0x5e3de0 (Missing UUID 4c4c444355553144a1942736321a049f)
5 Flutter 0x5e69f8 (Missing UUID 4c4c444355553144a1942736321a049f)
6 webview_flutter_wkwebview 0x10fd0 (Missing UUID 77fb8f2ca38a37d4a730288634b0a912)
7 webview_flutter_wkwebview 0xfd1c (Missing UUID 77fb8f2ca38a37d4a730288634b0a912)
8 libswiftCore.dylib 0x3d817c _swift_release_dealloc
9 libswiftCore.dylib 0x3d9290 bool swift::RefCounts<swift::RefCountBitsT<(swift::RefCountInlinedness)1>>::doDecrementSlow<(swift::PerformDeinit)1>(swift::RefCountBitsT<(swift::RefCountInlinedness)1>, unsigned int)
10 libobjc.A.dylib 0x53b0 _object_remove_associations
11 libobjc.A.dylib 0x4f5c objc_destructInstance
12 libobjc.A.dylib 0x4eec _objc_rootDealloc
13 UIKitCore 0x989ec -[UIResponder dealloc]
14 UIKitCore 0x9871c -[UIView dealloc]
15 WebKit 0x58dd18 (Missing UUID 82158fd18f2e3f94ac212078b4c4b99a)
16 Foundation 0x199054 _NSKVOPerformWithDeallocatingObservable
17 Foundation 0x198d68 NSKVODeallocate
18 libobjc.A.dylib 0x5bac object_cxxDestructFromClass(objc_object*, objc_class*)
19 libobjc.A.dylib 0x4f4c objc_destructInstance
20 libobjc.A.dylib 0x4eec _objc_rootDealloc
21 Flutter 0x3639c (Missing UUID 4c4c444355553144a1942736321a049f)
22 Flutter 0x36024 (Missing UUID 4c4c444355553144a1942736321a049f)
23 libobjc.A.dylib 0x5bac object_cxxDestructFromClass(objc_object*, objc_class*)
24 libobjc.A.dylib 0x4f4c objc_destructInstance
25 libobjc.A.dylib 0x4eec _objc_rootDealloc
26 Flutter 0x52ea4 (Missing UUID 4c4c444355553144a1942736321a049f)
27 CoreFoundation 0x4e488 __CFNOTIFICATIONCENTER_IS_CALLING_OUT_TO_AN_OBSERVER__
28 CoreFoundation 0x4e3a4 ___CFXRegistrationPost_block_invoke
29 CoreFoundation 0x4cf18 _CFXRegistrationPost
30 CoreFoundation 0x4c01c _CFXNotificationPost
31 Foundation 0x9fa9c -[NSNotificationCenter postNotificationName:object:userInfo:]
32 UIKitCore 0x115c528 -[UIApplication _terminateWithStatus:]
33 UIKitCore 0x1b5644 -[_UISceneLifecycleMultiplexer _evalTransitionToSettings:fromSettings:forceExit:withTransitionStore:]
34 UIKitCore 0x906e8c -[_UISceneLifecycleMultiplexer forceExitWithTransitionContext:scene:]
35 UIKitCore 0x1157c28 -[UIApplication workspaceShouldExit:withTransitionContext:]
36 FrontBoardServices 0x56cd4 __63-[FBSWorkspaceScenesClient willTerminateWithTransitionContext:]_block_invoke_2
37 FrontBoardServices 0x1f4c8 -[FBSWorkspace _calloutQueue_executeCalloutFromSource:withBlock:]
38 FrontBoardServices 0x56c74 __63-[FBSWorkspaceScenesClient willTerminateWithTransitionContext:]_block_invoke
39 libdispatch.dylib 0x3fa8 _dispatch_client_callout
40 libdispatch.dylib 0x79f0 _dispatch_block_invoke_direct
41 FrontBoardServices 0x18378 __FBSSERIALQUEUE_IS_CALLING_OUT_TO_A_BLOCK__
42 FrontBoardServices 0x182f8 -[FBSMainRunLoopSerialQueue _targetQueue_performNextIfPossible]
43 FrontBoardServices 0x181d0 -[FBSMainRunLoopSerialQueue _performNextFromRunLoopSource]
44 CoreFoundation 0x73f4c __CFRUNLOOP_IS_CALLING_OUT_TO_A_SOURCE0_PERFORM_FUNCTION__
45 CoreFoundation 0x73ee0 __CFRunLoopDoSource0
46 CoreFoundation 0x76b40 __CFRunLoopDoSources0
47 CoreFoundation 0x75d3c __CFRunLoopRun
48 CoreFoundation 0xc8284 CFRunLoopRunSpecific
49 GraphicsServices 0x14c0 GSEventRunModal
50 UIKitCore 0x3ee674 -[UIApplication _run]
51 UIKitCore 0x14e88 UIApplicationMain
52 UIKitCore 0x75115c keypath_get_selector_hoverStyle
53 Runner 0x8a38 main (AppDelegate.swift)
54 ??? 0x1c7c1dde8 (Missing)
Expected results
The app should not crash, or give me a better error description to fix it.
Actual results
App is crashing.
Code sample
Screenshots or Video
Logs
Logs
Fatal Exception: NSInternalInconsistencyException
0 CoreFoundation 0x2d5fc __exceptionPreprocess
1 libobjc.A.dylib 0x31244 objc_exception_throw
2 Foundation 0x82dec0 _userInfoForFileAndLine
3 Flutter 0x1fcc4 (Missing UUID 4c4c444355553144a1942736321a049f)
4 Flutter 0x5e3de0 (Missing UUID 4c4c444355553144a1942736321a049f)
5 Flutter 0x5e69f8 (Missing UUID 4c4c444355553144a1942736321a049f)
6 webview_flutter_wkwebview 0x10fd0 (Missing UUID 77fb8f2ca38a37d4a730288634b0a912)
7 webview_flutter_wkwebview 0xfd1c (Missing UUID 77fb8f2ca38a37d4a730288634b0a912)
8 libswiftCore.dylib 0x3d817c _swift_release_dealloc
9 libswiftCore.dylib 0x3d9290 bool swift::RefCounts<swift::RefCountBitsT<(swift::RefCountInlinedness)1>>::doDecrementSlow<(swift::PerformDeinit)1>(swift::RefCountBitsT<(swift::RefCountInlinedness)1>, unsigned int)
10 libobjc.A.dylib 0x53b0 _object_remove_associations
11 libobjc.A.dylib 0x4f5c objc_destructInstance
12 libobjc.A.dylib 0x4eec _objc_rootDealloc
13 UIKitCore 0x989ec -[UIResponder dealloc]
14 UIKitCore 0x9871c -[UIView dealloc]
15 WebKit 0x58dd18 (Missing UUID 82158fd18f2e3f94ac212078b4c4b99a)
16 Foundation 0x199054 _NSKVOPerformWithDeallocatingObservable
17 Foundation 0x198d68 NSKVODeallocate
18 libobjc.A.dylib 0x5bac object_cxxDestructFromClass(objc_object*, objc_class*)
19 libobjc.A.dylib 0x4f4c objc_destructInstance
20 libobjc.A.dylib 0x4eec _objc_rootDealloc
21 Flutter 0x3639c (Missing UUID 4c4c444355553144a1942736321a049f)
22 Flutter 0x36024 (Missing UUID 4c4c444355553144a1942736321a049f)
23 libobjc.A.dylib 0x5bac object_cxxDestructFromClass(objc_object*, objc_class*)
24 libobjc.A.dylib 0x4f4c objc_destructInstance
25 libobjc.A.dylib 0x4eec _objc_rootDealloc
26 Flutter 0x52ea4 (Missing UUID 4c4c444355553144a1942736321a049f)
27 CoreFoundation 0x4e488 __CFNOTIFICATIONCENTER_IS_CALLING_OUT_TO_AN_OBSERVER__
28 CoreFoundation 0x4e3a4 ___CFXRegistrationPost_block_invoke
29 CoreFoundation 0x4cf18 _CFXRegistrationPost
30 CoreFoundation 0x4c01c _CFXNotificationPost
31 Foundation 0x9fa9c -[NSNotificationCenter postNotificationName:object:userInfo:]
32 UIKitCore 0x115c528 -[UIApplication _terminateWithStatus:]
33 UIKitCore 0x1b5644 -[_UISceneLifecycleMultiplexer _evalTransitionToSettings:fromSettings:forceExit:withTransitionStore:]
34 UIKitCore 0x906e8c -[_UISceneLifecycleMultiplexer forceExitWithTransitionContext:scene:]
35 UIKitCore 0x1157c28 -[UIApplication workspaceShouldExit:withTransitionContext:]
36 FrontBoardServices 0x56cd4 __63-[FBSWorkspaceScenesClient willTerminateWithTransitionContext:]_block_invoke_2
37 FrontBoardServices 0x1f4c8 -[FBSWorkspace _calloutQueue_executeCalloutFromSource:withBlock:]
38 FrontBoardServices 0x56c74 __63-[FBSWorkspaceScenesClient willTerminateWithTransitionContext:]_block_invoke
39 libdispatch.dylib 0x3fa8 _dispatch_client_callout
40 libdispatch.dylib 0x79f0 _dispatch_block_invoke_direct
41 FrontBoardServices 0x18378 __FBSSERIALQUEUE_IS_CALLING_OUT_TO_A_BLOCK__
42 FrontBoardServices 0x182f8 -[FBSMainRunLoopSerialQueue _targetQueue_performNextIfPossible]
43 FrontBoardServices 0x181d0 -[FBSMainRunLoopSerialQueue _performNextFromRunLoopSource]
44 CoreFoundation 0x73f4c __CFRUNLOOP_IS_CALLING_OUT_TO_A_SOURCE0_PERFORM_FUNCTION__
45 CoreFoundation 0x73ee0 __CFRunLoopDoSource0
46 CoreFoundation 0x76b40 __CFRunLoopDoSources0
47 CoreFoundation 0x75d3c __CFRunLoopRun
48 CoreFoundation 0xc8284 CFRunLoopRunSpecific
49 GraphicsServices 0x14c0 GSEventRunModal
50 UIKitCore 0x3ee674 -[UIApplication _run]
51 UIKitCore 0x14e88 UIApplicationMain
52 UIKitCore 0x75115c keypath_get_selector_hoverStyle
53 Runner 0x8a38 main (AppDelegate.swift)
54 ??? 0x1c7c1dde8 (Missing)
Flutter Doctor output
Doctor output
[✓] Flutter (Channel stable, 3.29.2, on macOS 15.3.2 24D81 darwin-arm64, locale de-DE) [823ms]
• Flutter version 3.29.2 on channel stable at /Users/christiankonnerth/fvm/versions/3.29.2
• Upstream repository https://github.com/flutter/flutter.git
• Framework revision c236373904 (6 weeks ago), 2025-03-13 16:17:06 -0400
• Engine revision 18b71d647a
• Dart version 3.7.2
• DevTools version 2.42.3
[✓] Android toolchain - develop for Android devices (Android SDK version 35.0.1) [1.284ms]
• Android SDK at /Users/christiankonnerth/Library/Android/sdk
• Platform android-35, build-tools 35.0.1
• Java binary at: /opt/homebrew/Cellar/openjdk@17/17.0.14/libexec/openjdk.jdk/Contents/Home/bin/java
This JDK is specified in your Flutter configuration.
To change the current JDK, run: `flutter config --jdk-dir="path/to/jdk"`.
• Java version OpenJDK Runtime Environment Homebrew (build 17.0.14+0)
• All Android licenses accepted.
[✓] Xcode - develop for iOS and macOS (Xcode 16.1) [910ms]
• Xcode at /Applications/Xcode.app/Contents/Developer
• Build 16B40
• CocoaPods version 1.16.2
[✓] Chrome - develop for the web [9ms]
• Chrome at /Applications/Google Chrome.app/Contents/MacOS/Google Chrome
[✓] Android Studio (version 2024.3) [9ms]
• Android Studio at /Applications/Android Studio.app/Contents
• 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 21.0.5+-13047016-b750.29)
[✓] Connected device (5 available) [8,9s]
• iPhone von Chris (mobile) • 00008120-000E20E43E44C01E • ios • iOS 18.1.1 22B91
• iPhone 16 Pro (mobile) • A70C6685-6F1B-478E-942C-512E33DB11CD • ios • com.apple.CoreSimulator.SimRuntime.iOS-18-1 (simulator)
• macOS (desktop) • macos • darwin-arm64 • macOS 15.3.2 24D81 darwin-arm64
• Mac Designed for iPad (desktop) • mac-designed-for-ipad • darwin • macOS 15.3.2 24D81 darwin-arm64
• Chrome (web) • chrome • web-javascript • Google Chrome 135.0.7049.96
[✓] Network resources [887ms]
• All expected network resources are available.
• No issues found!Metadata
Metadata
Assignees
Labels
c: crashStack traces logged to the consolec: fatal crashCrashes that terminate the processfyi-ecosystemFor the attention of Ecosystem teamp: webviewThe WebView pluginpackageflutter/packages repository. See also p: labels.platform-iosiOS applications specificallyteam-iosOwned by iOS platform team

Activity
danagbemava-nc commentedon Apr 24, 2025
Hi @DieGlueckswurst, the flutter frames are missing UUID, can you try to symbolicate those using this document to see if you can get more meaningful logs ?
DieGlueckswurst commentedon Apr 24, 2025
@danagbemava-nc don't uite know how I can get the dsym from an older app version 🤔 I've already published an update where I downgraded to 3.29.2, hopefully that fixes things.
Is it maybe related to: #166677 ?
DieGlueckswurst commentedon Apr 24, 2025
Update:
The issue seems indeed to be happening when the webview is open and the user kills the app. I tested it and got this error in my XCode Console:
Even though its apparently not actually crashing the app because the app was closed anyway, Apple seems to recognize it as "fatal crash" and considers it in its analysis.
Quite critical for our app, as downloads are still going down, depending on the ranking.
Update 2.0
apparently this also happens when the WebView is already closed again. Is there something wrong with the disposel of it?
Couldn't find anything about it, but getting more and more erros shown.
danagbemava-nc commentedon Apr 28, 2025
Hi @DieGlueckswurst, have you found a way to reproduce this issue locally? That would help us to be able to come up with a fix for it
DieGlueckswurst commentedon Apr 28, 2025
yes! @danagbemava-nc . quite simple: Open the WebView on iOS (latest Flutter Version) and shut the app down manually by swiping up on iOS and removing the app. You will see the error in the logs on XCode
csandovalgd commentedon Apr 28, 2025
This is also happening for me, this is what I see on my log service:
danagbemava-nc commentedon Apr 29, 2025
Hi @DieGlueckswurst, does this also happen with the webview sample app? Also, what version of webview_flutter and webview_flutter_wkwebview are resolved in your project? This can be found in your pubspec.lock
DieGlueckswurst commentedon Apr 29, 2025
@danagbemava-nc using the latest version,
webview_flutter: ^4.11.0. Could you not reproduce it? I always tested it with a real device, iOS 18.19 remaining items
[-]Fatal Exception: NSInternalInconsistencyException: Sending a message before the FlutterEngine has been run.[/-][+][webview] Crash during app termination: Fatal Exception: NSInternalInconsistencyException: Sending a message before the FlutterEngine has been run.[/+]stuartmorgan-g commentedon Jun 3, 2025
This is a duplicate of #168535
The stack here cannot possibly be happening on random actions; it can only be triggered by manually terminating the app while it is frontmost.
If you have crashes that happen at other times, please file a new issue.
It's not clear to me what this is referring to. This won't be user-visible because it's crashing while terminating, so the behavior from a user standpoint—the app is no longer running—is the expected behavior.
UIApplicationtermination #168535stuartmorgan-g commentedon Jun 3, 2025
Thanks for clarifying; that's new behavior since the last time I dealt with a termination-specific crash on iOS.
github-actions commentedon Jun 17, 2025
This thread has been automatically locked since there has not been any recent activity after it was closed. If you are still experiencing a similar issue, please open a new bug, including the output of
flutter doctor -vand a minimal reproduction of the issue.