Skip to content
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

Crash on [cleanUpWebsocketOutputStream] function #5322

Closed
ZouhirASSAIB opened this issue May 6, 2024 · 7 comments
Closed

Crash on [cleanUpWebsocketOutputStream] function #5322

ZouhirASSAIB opened this issue May 6, 2024 · 7 comments
Labels
bug Something isn't working iot Issues related to the IoT SDK

Comments

@ZouhirASSAIB
Copy link

Describe the bug
Our major crash is coming from AWS SDK and specially the function 'cleanUpWebsocketOutputStream'. The crash occurs 100% of the time in background on every devices running iOS "17". Unfortunately, we are not able to reproduce the crash on our side...

Stack Trace

Crashed: com.apple.root.default-qos
0  CoreFoundation                 0x7038 CF_IS_OBJC + 24
1  CoreFoundation                 0x13378 CFArrayGetCount + 32
2  CoreFoundation                 0xdd1c _CFStreamClose + 264
3  AWSIoT                         0x78fc -[AWSIoTMQTTClient cleanUpWebsocketOutputStream] + 702 (AWSIoTMQTTClient.m:702)
4  AWSIoT                         0xaba0 -[AWSIoTMQTTClient webSocket:didCloseWithCode:reason:wasClean:] + 1291 (AWSIoTMQTTClient.m:1291)
5  AWSIoT                         0x8293c __41-[AWSSRWebSocket safeHandleEvent:stream:]_block_invoke_2 + 1595 (AWSSRWebSocket.m:1595)
6  libdispatch.dylib              0x213c _dispatch_call_block_and_release + 32
7  libdispatch.dylib              0x3dd4 _dispatch_client_callout + 20
8  libdispatch.dylib              0x6f6c _dispatch_queue_override_invoke + 928
9  libdispatch.dylib              0x15894 _dispatch_root_queue_drain + 392
10 libdispatch.dylib              0x1609c _dispatch_worker_thread2 + 156
11 libsystem_pthread.dylib        0x1ee4 _pthread_wqthread + 228
12 libsystem_pthread.dylib        0x1fc0 start_wqthread + 8

Unique Configuration
Since the crash occurs 100% of the time in background, it may be link to the fact we force the disconnection to the iOT when the app didEnterBackground. We made this to reduce other crashs on the SDK when the user was returning to the application. Maybe an asynchronous process end up after the disconnection and cause the crash...

Areas of the SDK you are using (AWSMobileClient, Cognito, Pinpoint, IoT, etc)?
AWSCognito.framework
AWSCognitoAuth.framework
AWSCognitoIdentityProvider.framework
AWSCognitoIdentityProviderASF.framework
AWSCore.framework

Environment(please complete the following information):

  • SDK Version: 2.33.10
  • Dependency Manager: Swift Package Manager (SPM)
  • Swift Version : 5
  • Xcode Version: 15.2

Device Information (please complete the following information):

  • Device: All versions
  • iOS Version: iOS 17

Thank you for your help on this. Our crash-free is very impacted by this one !

@ruisebas ruisebas added bug Something isn't working iot Issues related to the IoT SDK labels May 6, 2024
@ruisebas
Copy link
Member

ruisebas commented May 6, 2024

Hi @ZouhirASSAIB, thanks for opening this issue.

The team will take a look and post updates here. In the meantime, would you mind sharing:

  • The full symbolicated crashlog
  • Code snippets on how you're interacting with the AWSIoT APIs
  • Whether this issue happens exclusively on iOS 17, or in previous versions as well.

Thanks!

@ZouhirASSAIB
Copy link
Author

Hi @ZouhirASSAIB, thanks for opening this issue.

The team will take a look and post updates here. In the meantime, would you mind sharing:

  • The full symbolicated crashlog
  • Code snippets on how you're interacting with the AWSIoT APIs
  • Whether this issue happens exclusively on iOS 17, or in previous versions as well.

Thanks!

You're welcome @ruisebas 😊

Here is the full symbolicate crash log :

com.groupeseb.aspi-robot_issue_625efd37ea145feb6a8857d3ab58a6f7_crash_session_64d813839c0f439eaa99700d1f0fe0ed_DNE_0_v2_stacktrace.txt

Unfortunately, we can't send code snippets on how we're interacting with the AWSIoT APIs (corporate code).

And yes for now we have events that concerns only iOS 17.

@thisisabhash
Copy link
Member

Thank you - our team will investigate and post updates here.

@grifas
Copy link

grifas commented Jun 27, 2024

Hello @ruisebas @thisisabhash Any news about this issue ?

@harsh62
Copy link
Member

harsh62 commented Jul 11, 2024

@grifas We are still unable to reproduce this crash in our local environment. Are you able to provide detailed steps to reproduce this issue?

@ruisebas ruisebas added the pending-community-response Issue is pending response from the issue requestor label Jul 30, 2024
@ruisebas
Copy link
Member

Closing due to inactivity. Additionally, there's been a number of IoT bug fixes and improvements since 2.33.10 that addressed similar crashes.

@ruisebas ruisebas closed this as not planned Won't fix, can't repro, duplicate, stale Sep 27, 2024
@github-actions github-actions bot removed the pending-community-response Issue is pending response from the issue requestor label Sep 27, 2024
Copy link

This issue is now closed. Comments on closed issues are hard for our team to see.
If you need more assistance, please open a new issue that references this one.
If you wish to keep having a conversation with other community members under this issue feel free to do so.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working iot Issues related to the IoT SDK
Projects
None yet
Development

No branches or pull requests

5 participants