plus_plugins icon indicating copy to clipboard operation
plus_plugins copied to clipboard

Crash on IOS

Open Wackymax opened this issue 3 years ago • 8 comments

Hi, I've been getting some crash reports lately that looks like it's related to sensors plus. It seems like this happens when the app has been running in the background (still active) for a while and is then brought to the foregrounds again. I am using the accelerometer events from this package.

image image

System info

Platform the Issue occurs on: Plugin name: sensors_plus Plugin version: ^1.3.0

Steps to Reproduce

I am not quite sure how to reproduce this, it only happens to some users in some circumstances. Having local development logs would also not help I think considering things work fine for the most part.

Wackymax avatar Feb 27 '22 12:02 Wackymax

Same crash, but after I forcably close my app

melbek avatar Mar 05 '22 21:03 melbek

I am getting the same with connectivity_plus package.

This is the raw crash report from Sentry:

`Exception Type: EXC_CRASH (SIGABRT) Crashed Thread: 18

Application Specific Information: Sending a message before the FlutterEngine has been run.

Thread 18 Crashed: 0 CoreFoundation 0x3013950fc __exceptionPreprocess 1 libobjc.A.dylib 0x3324b9d60 objc_exception_throw 2 Foundation 0x304476398 -[NSAssertionHandler handleFailureInMethod:object:file:lineNumber:description:] 3 Flutter 0x10107a6c4 4 connectivity_plus 0x100cf8eac thunk for closure 5 connectivity_plus 0x100cf9aa0 SwiftConnectivityPlusPlugin.init 6 connectivity_plus 0x100cf809c PathMonitorConnectivityProvider.ensurePathMonitor 7 libswiftNetwork.dylib 0x3e2423ffc NWPathMonitor.init 8 libswiftNetwork.dylib 0x3e23f2ac0 thunk for closure 9 libnetwork.dylib 0x3034f17c0 __nw_path_necp_update_evaluator_block_invoke 10 libdispatch.dylib 0x300d0c920 _dispatch_call_block_and_release 11 libdispatch.dylib 0x300d0e66c _dispatch_client_callout 12 libdispatch.dylib 0x300d1fefc _dispatch_root_queue_drain 13 libdispatch.dylib 0x300d20604 _dispatch_worker_thread2 14 libsystem_pthread.dylib 0x3e29490b4 _pthread_wqthread 15 libsystem_pthread.dylib 0x3e2948e90 start_wqthread`

MilosKarakas avatar May 06 '22 09:05 MilosKarakas

From what I can see NWPathMonitor was introduced in connectivity_plus 2.3.0, so this could be related to that.

MilosKarakas avatar May 06 '22 09:05 MilosKarakas

I am getting the same with connectivity_plus package(2.3.0).

Fatal Exception: NSInternalInconsistencyException Sending a message before the FlutterEngine has been run. CoreFoundation __exceptionPreprocess Foundation _userInfoForFileAndLine Flutter -[FlutterEngine sendOnChannel:message:binaryReply:] connectivity_plus thunk for @escaping @callee_unowned @convention(block) (@unowned Swift.AnyObject?) -> () connectivity_plus SwiftConnectivityPlusPlugin.swift - Line 72 partial apply for implicit closure #2 in implicit closure #1 in SwiftConnectivityPlusPlugin.init(connectivityProvider:) + 72 connectivity_plus partial apply for implicit closure #2 in implicit closure #1 in PathMonitorConnectivityProvider.ensurePathMonitor() libswiftNetwork.dylib closure #1 in NWPathMonitor.init(requiredInterfaceType:) libsystem_pthread.dylib start_wqthread

jveryspace avatar May 09 '22 07:05 jveryspace

Same issue. Fatal Exception: NSInternalInconsistencyException Sending a message before the FlutterEngine has been run.

System info

Platform the Issue occurs on: iOS 15, Flutter v2.10.3 Plugin name: connectivity_plus Plugin version: 2.3.0 Device states: 99% background

Fatal Exception: NSInternalInconsistencyException
0  CoreFoundation                 0x99d78 __exceptionPreprocess
1  libobjc.A.dylib                0x16734 objc_exception_throw
2  Foundation                     0x1311f0 _userInfoForFileAndLine
3  Flutter                        0x126cc (Missing UUID be105c8b7c053a8ba51f83e291732357)
4  connectivity_plus              0x8ea4 thunk for @escaping @callee_unowned @convention(block) (@unowned Swift.AnyObject?) -> () (<compiler-generated>)
5  connectivity_plus              0x9aa0 partial apply for implicit closure #2 in implicit closure #1 in SwiftConnectivityPlusPlugin.init(connectivityProvider:) + 72 (SwiftConnectivityPlusPlugin.swift:72)
6  connectivity_plus              0x809c partial apply for implicit closure #2 in implicit closure #1 in PathMonitorConnectivityProvider.ensurePathMonitor() (<compiler-generated>)
7  libswiftNetwork.dylib          0x361c0 closure #1 in NWPathMonitor.init(requiredInterfaceType:)
8  libswiftNetwork.dylib          0x2c80 thunk for @escaping @callee_guaranteed (@guaranteed OS_nw_path) -> ()
9  libnetwork.dylib               0x804ae0 __nw_path_necp_update_evaluator_block_invoke
10 libdispatch.dylib              0x1e68 _dispatch_call_block_and_release
11 libdispatch.dylib              0x3a2c _dispatch_client_callout
12 libdispatch.dylib              0x15280 _dispatch_root_queue_drain
13 libdispatch.dylib              0x1596c _dispatch_worker_thread2
14 libsystem_pthread.dylib        0x1080 _pthread_wqthread
15 libsystem_pthread.dylib        0xe5c start_wqthread```

solikhver avatar May 09 '22 09:05 solikhver

same same same sensors_plus: ^1.3.2

cnkygmr avatar Jul 27 '22 20:07 cnkygmr

@cnkygmr can you check with 1.3.3?

followthemoney1 avatar Jul 29 '22 11:07 followthemoney1

@followthemoney1 yes problem solved

cnkygmr avatar Jul 29 '22 11:07 cnkygmr

This issue is stale because it has been open 60 days with no activity. Remove stale label or comment or this will be closed in 15 days

github-actions[bot] avatar Dec 28 '22 00:12 github-actions[bot]