-
Notifications
You must be signed in to change notification settings - Fork 25
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
UI stuck at unsubscribe or calling subscribe when connection disconnected #673
Comments
@shoaibahmedqureshi on which target is this happening? iOS9, 10, 11? |
I currently tested it on ios 11 |
@shoaibahmedqureshi Are you by chance adding an observer to |
I am using NSNotificationCenter on main screen and i am not removing it in viewWillDisappear as if someone subscribe on other screens I want that update to be reflected there. |
Btw I just added removeObserver statement in my viewWillDisappear method. override func viewWillDisappear(_ animated: Bool) { I am still able to reproduce this issue. |
@shoaibahmedqureshi It looks like the issue is triggered from here: https://github.com/ably/ably-ios/blob/f87bb50176b89ac8a92318bf4fe03094ea28a6b0/Source/ARTConnection.m#L84 when you (or indirectly the code you wrote) asks for the value of |
yes i am performing ably operations on background thread and before every call i try to check the ably connection status and yes crash occurs somewhere around this. no i am not accessing ably in AppDelegate my app delegate looks something like
} |
@shoaibahmedqureshi Update as per our calls:
Things we explored:
Hint There should be some code like this (of Swift equivalent):
that triggers the deadlock. It's still not clear if this is part of Ably SDK or not. Action: build a simple project that tries to reproduce this behavior. |
@funkyboy So, you suspect it's a deadlock? When it hangs, do you saw any |
@shoaibahmedqureshi in the meantime, see the question above. |
@ricardopereira during the debugging process we explored the code and in my application's code most of calls I had were asynchronous except a couple of serial ques I was using before marker drawing to avoid race condition so we commented them out to find out if they are the real culprit but issue was reproducible without them too. I am not sure about calls within ably library though. |
@shoaibahmedqureshi will build a sample project tomorrow, trying to replicate this. |
@shoaibahmedqureshi Here is my sample project, but I couldn't manage to make the UI hang. Feel free to fork and tweak. |
@funkyboy I will try to tweak and will let u know if i am able to and reproduce this issue. |
@shoaibahmedqureshi Closing this. Feel free to reopen if this is still an issue. |
I am experiencing a crashing issue using pod version 'Ably', '1.0.10' . I have seen a couple of crashing issue fixes and I am not sure if it's fix is a part of the new release or not and because of this crash UI gets hanged often and does not respond. Below is the stack trace for the crash for further clearance.
Thread says something like below:
KSCrashAblyFork`monitorCachedData(userData=0x000000010db0e54e) at KSCrashCachedData.c:148
Crash back trace.txt
The text was updated successfully, but these errors were encountered: