Closed saddy001 closed 2 years ago
Because the error above looked like an out of memory exception to me ("VM - Fault hit memory shortage"), I reduced the camera resolution for iOS and now I have a different stack trace for the iPhone 6s. On Android, it is working fine. I also tested on an iPhone 11 and it's also crashing.
Hi, how are you able to bring up a stacktrace? I just get "Lost Connection to Device" when trying to perform text recognition
Try the latest version.
Also note that google_ml_kit
has been split in multiples plugins, to avoid adding unnecessary dependencies to your project.
More details here:
I have it crashing on an iPhone 6s using the TextRecognizer. Here's the stacktrace:
iPhone 6s stacktrace
Incident Identifier: xxxxx Hardware Model: iPhone8,1 Process: Runner [438] Path: /private/var/containers/Bundle/Application/xxxxx/Runner.app/Runner Identifier: xxxxx Version: 3.3.1 (38) AppStoreTools: 13C90b AppVariant: 1:iPhone8,1:15 Beta: YES Code Type: ARM-64 (Native) Role: Foreground Parent Process: launchd [1] Coalition: xxxxx [614] Date/Time: 2022-01-02 19:22:18.8185 +0100 Launch Time: 2022-01-02 19:22:14.6368 +0100 OS Version: iPhone OS 15.2 (19C56) Release Type: User Baseband Version: 9.01.00 Report Version: 104 Exception Type: EXC_CRASH (SIGABRT) Exception Codes: 0x0000000000000000, 0x0000000000000000 Exception Note: EXC_CORPSE_NOTIFY Triggered by Thread: 0 Last Exception Backtrace: 0 CoreFoundation 0x183735d3c __exceptionPreprocess + 216 (NSException.m:200) 1 libobjc.A.dylib 0x19aa9a6a8 objc_exception_throw + 56 (objc-exception.mm:565) 2 CoreFoundation 0x183788da4 +[NSException raise:format:] + 108 (NSException.m:156) 3 Runner 0x1054b94e8 0x10436c000 + 18142440 4 Runner 0x1054bad5c 0x10436c000 + 18148700 5 Runner 0x1054bacdc 0x10436c000 + 18148572 6 Runner 0x1043735bc -[GULCCComponentContainer instantiateInstanceForProtocol:withBlock:] + 68 (GULCCComponentContainer.m:147) 7 Runner 0x104373774 -[GULCCComponentContainer instanceForProtocol:] + 224 (GULCCComponentContainer.m:181) 8 Runner 0x104373aa4 +[GULCCComponentType instanceForProtocol:inContainer:] + 48 (GULCCComponentType.m:25) 9 Runner 0x1044d7d74 0x10436c000 + 1490292 10 Runner 0x1044d720c 0x10436c000 + 1487372 11 Runner 0x1044d7464 0x10436c000 + 1487972 12 Runner 0x1044d58c8 0x10436c000 + 1480904 13 Runner 0x1044d576c 0x10436c000 + 1480556 14 Runner 0x105e0152c 0x10436c000 + 27874604 15 Runner 0x1082ebd40 -[TextRecognizer handleDetection:result:] + 204 (TextRecognizer.m:28) 16 Runner 0x1082ebbf0 -[TextRecognizer handleMethodCall:result:] + 152 (TextRecognizer.m:19) 17 Runner 0x1082e8148 -[GoogleMlKitPlugin handleMethodCall:result:] + 188 (GoogleMlKitPlugin.m:37) 18 Flutter 0x10aa7fc54 0x10a590000 + 5176404 19 Flutter 0x10a5cc664 0x10a590000 + 247396 20 Flutter 0x10a94c204 0x10a590000 + 3916292 21 Flutter 0x10a87b0d8 0x10a590000 + 3059928 22 Flutter 0x10a87e6a4 0x10a590000 + 3073700 23 CoreFoundation 0x18374a06c __CFRUNLOOP_IS_CALLING_OUT_TO_A_TIMER_CALLBACK_FUNCTION__ + 28 (CFRunLoop.c:1812) 24 CoreFoundation 0x1836d43d8 __CFRunLoopDoTimer + 1016 (CFRunLoop.c:2420) 25 CoreFoundation 0x1836cf06c __CFRunLoopDoTimers + 324 (CFRunLoop.c:2580) 26 CoreFoundation 0x1836aef44 __CFRunLoopRun + 1948 (CFRunLoop.c:3116) 27 CoreFoundation 0x1836c1e1c CFRunLoopRunSpecific + 572 (CFRunLoop.c:3268) 28 GraphicsServices 0x1a3a1c9a0 GSEventRunModal + 160 (GSEvent.c:2200) 29 UIKitCore 0x185ef5600 -[UIApplication _run] + 1080 (UIApplication.m:3493) 30 UIKitCore 0x185c8ab08 UIApplicationMain + 2028 (UIApplication.m:5046) 31 Runner 0x1043726e4 main + 64 (AppDelegate.swift:5) 32 dyld 0x109664250 start + 444 (dyldMain.cpp:879) Kernel Triage: VM - Fault hit memory shortage VM - Fault hit memory shortage VM - Fault hit memory shortage VM - Fault hit memory shortage Thread 0 name: Thread 0 Crashed: 0 libsystem_kernel.dylib 0x00000001bd8099e8 __pthread_kill + 8 1 libsystem_pthread.dylib 0x00000001ddd8e824 pthread_kill + 208 (pthread.c:1668) 2 libsystem_c.dylib 0x000000018dc2d0b4 abort + 120 (abort.c:118) 3 libc++abi.dylib 0x000000019ab8fe1c abort_message + 128 (abort_message.cpp:78) 4 libc++abi.dylib 0x000000019ab81bec demangling_terminate_handler() + 296 (cxa_default_handlers.cpp:71) 5 libobjc.A.dylib 0x000000019aaa0018 _objc_terminate() + 124 (objc-exception.mm:701) 6 libc++abi.dylib 0x000000019ab8f2cc std::__terminate(void (*)()) + 16 (cxa_handlers.cpp:59) 7 libc++abi.dylib 0x000000019ab91e4c __cxa_rethrow + 144 (cxa_exception.cpp:616) 8 libobjc.A.dylib 0x000000019aa9c1e8 objc_exception_rethrow + 40 (objc-exception.mm:604) 9 CoreFoundation 0x00000001836c1f08 CFRunLoopRunSpecific + 808 (CFRunLoop.c:3283) 10 GraphicsServices 0x00000001a3a1c9a0 GSEventRunModal + 160 (GSEvent.c:2200) 11 UIKitCore 0x0000000185ef5600 -[UIApplication _run] + 1080 (UIApplication.m:3493) 12 UIKitCore 0x0000000185c8ab08 UIApplicationMain + 2028 (UIApplication.m:5046) 13 Runner 0x00000001043726e4 main + 64 (AppDelegate.swift:5) 14 dyld 0x0000000109664250 start + 444 (dyldMain.cpp:879) Thread 1 name: Thread 1: 0 libsystem_kernel.dylib 0x00000001bd8050ec __psynch_mutexdrop + 8 1 libsystem_pthread.dylib 0x00000001ddd85c5c _pthread_mutex_firstfit_wake + 24 (pthread_mutex.c:1317) 2 libsystem_pthread.dylib 0x00000001ddd8b830 _pthread_mutex_firstfit_unlock_slow$VARIANT$mp + 260 (pthread_mutex.c:1346) 3 libobjc.A.dylib 0x000000019aa92340 monitor_tt