Skip to content

-[AWSIoTStreamThread main] EXC_BREAKPOINT #5523

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

Open
ad-Jun opened this issue May 8, 2025 · 2 comments
Open

-[AWSIoTStreamThread main] EXC_BREAKPOINT #5523

ad-Jun opened this issue May 8, 2025 · 2 comments
Labels
bug Something isn't working pending-maintainer-response Issue is pending response from an Amplify team member

Comments

@ad-Jun
Copy link

ad-Jun commented May 8, 2025

Describe the bug
This crash occurred frequently online.I utilized the crash stack information monitored by firebase.

Environment(please complete the following information):

  • SDK Version: [2.40.2]
  • Dependency Manager: [Cocoapods]
  • Swift Version : [6.0]
  • Xcode Version: [16.2]

Device Information (please complete the following information):

  • Device: [iPhone15 Pro]
  • iOS Version: [iOS 18.4.1]
  • Specific to simulators:

INSERT LOG MESSAGES HERE

# Crashlytics - Stack trace
# Application: com.xxxx.xxxx
# Platform: apple
# Version: 2.2.1 (202504282015)
# Issue: 2df413d1d5c8f75c4f68c61519616807
# Session: 3c05ac473d9c4b1e8a5b527ffe306cd4_DNE_0_v2
# Date: Wed May 07 2025 11:18:38 GMT+0800 (中国标准时间)

com.apple.main-thread
0  libsystem_kernel.dylib         0xce4 mach_msg2_trap + 8
1  libsystem_kernel.dylib         0x439c mach_msg2_internal + 76
2  libsystem_kernel.dylib         0x42b8 mach_msg_overwrite + 428
3  libsystem_kernel.dylib         0x4100 mach_msg + 24
4  CoreFoundation                 0x716cc __CFRunLoopServiceMachPort + 160
5  CoreFoundation                 0x70dac __CFRunLoopRun + 1208
6  CoreFoundation                 0x95700 CFRunLoopRunSpecific + 572
7  GraphicsServices               0x1190 GSEventRunModal + 168
8  UIKitCore                      0x3ca240 -[UIApplication _run] + 816
9  UIKitCore                      0x3c8470 UIApplicationMain + 336
10 UIKitCore                      0x826a30 block_destroy_helper.15 + 9820
11 xxxx-RM-iOS                   0xe6e5cc static UIApplicationDelegate.main() + 4377241036 (<compiler-generated>:4377241036)
12 xxxx-RM-iOS                   0xe6c1e0 static AppDelegate.$main() + 4377231840 (<compiler-generated>:4377231840)
13 xxxx-RM-iOS                   0xe6e3c4 main + 40 (AppDelegate.swift:40)
14 ???                            0x1b60ffad8 (缺少)

com.apple.uikit.eventfetch-thread
0  libsystem_kernel.dylib         0xce4 mach_msg2_trap + 8
1  libsystem_kernel.dylib         0x439c mach_msg2_internal + 76
2  libsystem_kernel.dylib         0x42b8 mach_msg_overwrite + 428
3  libsystem_kernel.dylib         0x4100 mach_msg + 24
4  CoreFoundation                 0x716cc __CFRunLoopServiceMachPort + 160
5  CoreFoundation                 0x70dac __CFRunLoopRun + 1208
6  CoreFoundation                 0x95700 CFRunLoopRunSpecific + 572
7  Foundation                     0x748a8 -[NSRunLoop(NSRunLoop) runMode:beforeDate:] + 212
8  Foundation                     0x736d8 -[NSRunLoop(NSRunLoop) runUntilDate:] + 64
9  UIKitCore                      0x4bd5ec -[UIEventFetcher threadMain] + 424
10 Foundation                     0x115cf8 __NSThread__start__ + 732
11 libsystem_pthread.dylib        0x1afc _pthread_start + 136
12 libsystem_pthread.dylib        0x1a04 thread_start + 8

com.google.firebase.crashlytics.MachExceptionServer
0  FirebaseCrashlytics            0x1dc08 FIRCLSProcessRecordAllThreads + 392 (FIRCLSProcess.c:392)
1  FirebaseCrashlytics            0x1e014 FIRCLSProcessRecordAllThreads + 423 (FIRCLSProcess.c:423)
2  FirebaseCrashlytics            0x14df8 FIRCLSHandler + 34 (FIRCLSHandler.m:34)
3  FirebaseCrashlytics            0x17994 FIRCLSMachExceptionServer + 521 (FIRCLSMachException.c:521)
4  libsystem_pthread.dylib        0x1afc _pthread_start + 136
5  libsystem_pthread.dylib        0x1a04 thread_start + 8

com.apple.NSURLConnectionLoader
0  libsystem_kernel.dylib         0xce4 mach_msg2_trap + 8
1  libsystem_kernel.dylib         0x439c mach_msg2_internal + 76
2  libsystem_kernel.dylib         0x42b8 mach_msg_overwrite + 428
3  libsystem_kernel.dylib         0x4100 mach_msg + 24
4  CoreFoundation                 0x716cc __CFRunLoopServiceMachPort + 160
5  CoreFoundation                 0x70dac __CFRunLoopRun + 1208
6  CoreFoundation                 0x95700 CFRunLoopRunSpecific + 572
7  CFNetwork                      0xebeec +[__CFN_CoreSchedulingSetRunnable _run:] + 416
8  Foundation                     0x115cf8 __NSThread__start__ + 732
9  libsystem_pthread.dylib        0x1afc _pthread_start + 136
10 libsystem_pthread.dylib        0x1a04 thread_start + 8

com.squareup.SocketRocket.NetworkThread
0  libsystem_kernel.dylib         0xaf8 __ulock_wait2 + 8
1  libsystem_platform.dylib       0x3204 _os_unfair_lock_lock_slow + 176
2  CoreFoundation                 0x8d94 _CFStreamClose + 220
3  AWSIoT                         0x8ba5c -[AWSSRWebSocket _cleanupSelfReference:] + 1245 (AWSSRWebSocket.m:1245)
4  Foundation                     0x1da140 __NSFireTimer + 96
5  CoreFoundation                 0x94654 __CFRUNLOOP_IS_CALLING_OUT_TO_A_TIMER_CALLBACK_FUNCTION__ + 32
6  CoreFoundation                 0x94314 __CFRunLoopDoTimer + 980
7  CoreFoundation                 0x93e8c __CFRunLoopDoTimers + 288
8  CoreFoundation                 0x7102c __CFRunLoopRun + 1848
9  CoreFoundation                 0x95700 CFRunLoopRunSpecific + 572
10 Foundation                     0x748a8 -[NSRunLoop(NSRunLoop) runMode:beforeDate:] + 212
11 AWSIoT                         0x8d5a0 -[_SRRunLoopThread main] + 1905 (AWSSRWebSocket.m:1905)
12 Foundation                     0x115cf8 __NSThread__start__ + 732
13 libsystem_pthread.dylib        0x1afc _pthread_start + 136
14 libsystem_pthread.dylib        0x1a04 thread_start + 8

com.apple.CFSocket.private
0  libsystem_kernel.dylib         0x832c select$DARWIN_EXTSN + 8
1  libsystem_kernel.dylib         0x832c __select + 8
2  CoreFoundation                 0xc8b84 __CFSocketManager + 704
3  libsystem_pthread.dylib        0x1afc _pthread_start + 136
4  libsystem_pthread.dylib        0x1a04 thread_start + 8

Crashed: Thread
0  CoreFoundation                 0xea20 CF_IS_OBJC + 64
1  CoreFoundation                 0xfda48 _signalEventSync + 88
2  CoreFoundation                 0xfd97c _cfstream_shared_signalEventSync + 392
3  CoreFoundation                 0x72ce4 __CFRUNLOOP_IS_CALLING_OUT_TO_A_SOURCE0_PERFORM_FUNCTION__ + 28
4  CoreFoundation                 0x72c78 __CFRunLoopDoSource0 + 172
5  CoreFoundation                 0x719fc __CFRunLoopDoSources0 + 232
6  CoreFoundation                 0x70c3c __CFRunLoopRun + 840
7  CoreFoundation                 0x95700 CFRunLoopRunSpecific + 572
8  Foundation                     0x748a8 -[NSRunLoop(NSRunLoop) runMode:beforeDate:] + 212
9  AWSIoT                         0x8140c -[AWSIoTStreamThread main] + 98 (AWSIoTStreamThread.m:98)
10 Foundation                     0x115cf8 __NSThread__start__ + 732
11 libsystem_pthread.dylib        0x1afc _pthread_start + 136
12 libsystem_pthread.dylib        0x1a04 thread_start + 8

com.apple.root.default-qos
0  libsystem_kernel.dylib         0x6f18 __psynch_mutexwait + 8
1  libsystem_pthread.dylib        0x3a50 _pthread_mutex_firstfit_lock_wait + 84
2  libsystem_pthread.dylib        0x3698 _pthread_mutex_firstfit_lock_slow + 220
3  CoreFoundation                 0x8e84 _CFStreamClose + 460
4  AWSIoT                         0x60230 -[AWSIoTMQTTClient cleanUpWebsocketOutputStream] + 714 (AWSIoTMQTTClient.m:714)
5  AWSIoT                         0x63988 -[AWSIoTMQTTClient webSocket:didCloseWithCode:reason:wasClean:] + 1303 (AWSIoTMQTTClient.m:1303)
6  AWSIoT                         0x8cc94 __41-[AWSSRWebSocket safeHandleEvent:stream:]_block_invoke_2 + 1595 (AWSSRWebSocket.m:1595)
7  libdispatch.dylib              0x1aac _dispatch_call_block_and_release + 32
8  libdispatch.dylib              0x1b584 _dispatch_client_callout + 16
9  libdispatch.dylib              0x3725c _dispatch_queue_override_invoke.cold.3 + 32
10 libdispatch.dylib              0x61f8 _dispatch_queue_override_invoke + 848
11 libdispatch.dylib              0x13db0 _dispatch_root_queue_drain + 364
12 libdispatch.dylib              0x1454c _dispatch_worker_thread2 + 156
13 libsystem_pthread.dylib        0x4624 _pthread_wqthread + 232
14 libsystem_pthread.dylib        0x19f8 start_wqthread + 8

Thread
0  libsystem_pthread.dylib        0x19f0 start_wqthread + 142

Thread
0  libsystem_kernel.dylib         0xa90 __workq_kernreturn + 8
1  libsystem_pthread.dylib        0x46ac _pthread_wqthread + 368
2  libsystem_pthread.dylib        0x19f8 start_wqthread + 8

com.apple.root.default-qos
0  libsystem_kernel.dylib         0x6f18 __psynch_mutexwait + 8
1  libsystem_pthread.dylib        0x3a50 _pthread_mutex_firstfit_lock_wait + 84
2  libsystem_pthread.dylib        0x3698 _pthread_mutex_firstfit_lock_slow + 220
3  CoreFoundation                 0xfd070 _CFStreamCopyRunLoopsAndModes + 40
4  CoreFoundation                 0xfc998 _wakeWriteStreamScheduledRunLoops + 20
5  CoreFoundation                 0xfc938 boundPairWrite + 452
6  CoreFoundation                 0x24228 CFWriteStreamWrite + 312
7  AWSIoT                         0x637e0 -[AWSIoTMQTTClient webSocket:didReceiveMessage:] + 1290 (AWSIoTMQTTClient.m:1290)
8  AWSIoT                         0x8a944 __33-[AWSSRWebSocket _handleMessage:]_block_invoke + 836 (AWSSRWebSocket.m:836)
9  libdispatch.dylib              0x1aac _dispatch_call_block_and_release + 32
10 libdispatch.dylib              0x1b584 _dispatch_client_callout + 16
11 libdispatch.dylib              0x3725c _dispatch_queue_override_invoke.cold.3 + 32
12 libdispatch.dylib              0x61f8 _dispatch_queue_override_invoke + 848
13 libdispatch.dylib              0x13db0 _dispatch_root_queue_drain + 364
14 libdispatch.dylib              0x1454c _dispatch_worker_thread2 + 156
15 libsystem_pthread.dylib        0x4624 _pthread_wqthread + 232
16 libsystem_pthread.dylib        0x19f8 start_wqthread + 8

Thread
0  libsystem_kernel.dylib         0xa90 __workq_kernreturn + 8
1  libsystem_pthread.dylib        0x46ac _pthread_wqthread + 368
2  libsystem_pthread.dylib        0x19f8 start_wqthread + 8
@github-actions github-actions bot added pending-triage Issue is pending triage pending-maintainer-response Issue is pending response from an Amplify team member labels May 8, 2025
@thisisabhash thisisabhash added the bug Something isn't working label May 8, 2025
@thisisabhash
Copy link
Member

Hello, thank you for posting this. We have tried to release several improvements in previous releases. However, we have not been successful in reproducing the issue on our side. Would you be able to share a mini project/code that helps us reproduce this issue?

@github-actions github-actions bot removed the pending-maintainer-response Issue is pending response from an Amplify team member label May 8, 2025
@thisisabhash thisisabhash removed the pending-triage Issue is pending triage label May 8, 2025
@ad-Jun
Copy link
Author

ad-Jun commented May 28, 2025

We found that when we actively called the disconnect method of AWSIoTDataManager, the probability of these crashes occurring would increase significantly. Hope this is helpful for you to analyze the occurrence of bugs.
In addition, when I call the AWSIoTDataManager disconnect method, I'll call the reconnection connectUsingWebSocketWithClientId, whether this would be the cause of the crash occurred probability high?

@github-actions github-actions bot added the pending-maintainer-response Issue is pending response from an Amplify team member label May 28, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working pending-maintainer-response Issue is pending response from an Amplify team member
Projects
None yet
Development

No branches or pull requests

2 participants