Closed danhalliday closed 6 months ago
Hi @danhalliday, thanks for reporting.
Is this all the information from the crash log?
Is there any information about what the error is like this:
Exception Type: EXC_BREAKPOINT (SIGTRAP)
Exception Codes: 0x0000000000000001, 0x0000000102afb3d0
I don't have enough information to figure out what is happening here. Do you have any more information or other stack traces?
0 OneSignalOSCore 0x8c9c __swift_instantiateConcreteTypeFromMangledName + 3788
1 OneSignalUser 0x86fc __swift_project_boxed_opaque_existential_1 + 14568
Additionally, how many users / what percent of users have been affected by this crash?
Notes to self: looks like it may be in the method flushDeltaQueue
.
@nan-li Yes I’m afraid this is all I have from Crashlytics and the crash is rare enough that I never see it in development (but common enough with thousands of users that it’s a very real problem). Judging by your WIP PR it looks like there’s just a lot of code that isn’t thread safe, which is super disappointing.
What can I do from my side while the thread safety fixes are ongoing? Is it worth me locking around my calls to the SDK? Or is that not going to help because the issue is concurrent access to shared resources from threads within the SDK? Will it help for me to make all my SDK calls on the main thread?
@nan-li This one looks promising for 5.1.3. Not seen it again yet.
Saw this today from 5.1.3 in my Firebase. I think it's the same crash? Maybe not?
Crashed: OneSignal.OSOperationRepo
EXC_BAD_ACCESS KERN_INVALID_ADDRESS 0x0000000000000010
0 libobjc.A.dylib 0x4820 objc_msgSend + 32
1 Foundation 0x21b30 <redacted> + 180
2 OneSignalUser 0x12a14 __swift_destroy_boxed_opaque_existential_0 + 6928
3 OneSignalUser 0x12a74 __swift_destroy_boxed_opaque_existential_0 + 7024
4 Foundation 0x21f18 <redacted> + 1180
5 OneSignalOSCore 0xe634 __swift_destroy_boxed_opaque_existential_0 + 5612
6 OneSignalOSCore 0xe748 __swift_destroy_boxed_opaque_existential_0 + 5888
7 Foundation 0x21f18 <redacted> + 1180
8 Foundation 0x218b8 <redacted> + 460
9 Foundation 0x54008 <redacted> + 588
10 Foundation 0x21f18 <redacted> + 1180
11 Foundation 0x6e766c <redacted> + 104
12 OneSignalCore 0xd69c -[OneSignalUserDefaults saveCodeableDataForKey:withValue:] + 88
13 OneSignalOSCore 0x7db4 __swift_instantiateConcreteTypeFromMangledName + 2856
14 OneSignalOSCore 0x763c __swift_instantiateConcreteTypeFromMangledName + 944
15 libdispatch.dylib 0x26a8 <redacted> + 32
16 libdispatch.dylib 0x4300 <redacted> + 20
17 libdispatch.dylib 0xb894 <redacted> + 748
18 libdispatch.dylib 0xc3c4 <redacted> + 380
19 libdispatch.dylib 0x17004 <redacted> + 288
20 libdispatch.dylib 0x16878 <redacted> + 404
21 libsystem_pthread.dylib 0x1964 _pthread_wqthread + 288
22 libsystem_pthread.dylib 0x1a04 start_wqthread + 8
@ethanwa I think your crash is more likely this: https://github.com/OneSignal/OneSignal-iOS-SDK/issues/1365? Or perhaps they are the same root cause. There’s some very bad stuff going on with OneSignal’s user default implementation...
I'm having the same issue. I've posted also about another issue which might be relevant but still no updated on it: https://github.com/OneSignal/OneSignal-Flutter-SDK/issues/858
One thing I noted is the crash happens when not using cellular data (i.e not WiFi)
Hi @danhalliday thank you for following up this particular stacktrace seems resolved. I'll close out this issue and follow up with the rest of the crash reports.
HI @ethanwa, your stack trace looks exactly like this post: https://github.com/OneSignal/OneSignal-iOS-SDK/issues/1409. We released a fix for this crash in Release 5.1.6. Please update and let us know if your crashes are resolved, or what crashes are still ongoing.
What happened?
iOS app crashed in production with a stack trace showing OneSignal frames.
Steps to reproduce?
What did you expect to happen?
The library should not cause a crash, regardless of what I may be doing wrong in using it.
OneSignal iOS SDK version
5.1.0
iOS version
11 or below
Specific iOS version
Relevant log output
Code of Conduct