You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
This repository has been archived by the owner on Jan 19, 2018. It is now read-only.
The SDK violates the Core Data Multithreading contract which can lead to crashes.
This is AFAICT happens when calling any instance method of the Storage class without using the performBlock() method on the managed object context which happens if you do not use the SDK from the main thread. Since this is a tracking SDK non-main-thread usage should be the norm, not the exception.
Generally the managed object context of the Storage class is in .MainQueueConcurrencyType which is completely inappropriate for a tracking framework especially since the whole API is async. This type should only be used for UI work, which the SDK does not do.
Take a look at the core data concurrency documentation, this is really, really, really bad for a SDK. Esp. since it makes debugging your own core data driven app basically impossible.
Steps to reproduce
Integrate the SDK into your app
Launch the app with -com.apple.CoreData.ConcurrencyDebug 1 as a launch argument (set in the schemes)
Watch the exceptions
Expected Result
No multithreading violations
Workaround
Call any and all methods of the SDK only from the main queue/thread.
The text was updated successfully, but these errors were encountered:
Hi, we are aware of the problem and are currently working on it. The problem is that the SDK performs tracking but also has a small part of UI (the debugger feature), that's why we are still with .MainQueueConcurrencyType.
The performBlock fix is in progress and will be released soon.
Description
The SDK violates the Core Data Multithreading contract which can lead to crashes.
This is AFAICT happens when calling any instance method of the
Storage
class without using theperformBlock()
method on the managed object context which happens if you do not use the SDK from the main thread. Since this is a tracking SDK non-main-thread usage should be the norm, not the exception.Generally the managed object context of the
Storage
class is in.MainQueueConcurrencyType
which is completely inappropriate for a tracking framework especially since the whole API is async. This type should only be used for UI work, which the SDK does not do.Take a look at the core data concurrency documentation, this is really, really, really bad for a SDK. Esp. since it makes debugging your own core data driven app basically impossible.
Steps to reproduce
-com.apple.CoreData.ConcurrencyDebug 1
as a launch argument (set in the schemes)Expected Result
No multithreading violations
Workaround
Call any and all methods of the SDK only from the main queue/thread.
The text was updated successfully, but these errors were encountered: