qonversion-ios-sdk icon indicating copy to clipboard operation
qonversion-ios-sdk copied to clipboard

Data Races in QNUserPropertiesManager

Open Ralph1300 opened this issue 1 year ago • 5 comments

We recently experienced some data races in the QNUserPropertiesManager class. We are using Xcode 15 and have the Thread Sanitizer activated for debug builds.

See the attached screenshot for an example. This is usually triggered right after the app start, where we call Qonversion.initWithConfig() from the main thread in the AppDelegate.

As far as I can tell issues are related to

@property (nonatomic, assign, readwrite) BOOL sendingScheduled;
@property (nonatomic, assign, readwrite) BOOL updatingCurrently;

Both properties are read/written to on multiple occasions - sometimes updatingCurrently is wrapped in a synchronization block, but not always. For sendingScheduled this is missing completely.

Stack

Thanks for looking into this, and let me know if you need more input!

Ralph1300 avatar Feb 06 '24 08:02 Ralph1300

Hi, @Ralph1300 Thanks for the details. We will look deeper into this issue and come back with an update!

suriksarkisyan avatar Feb 06 '24 13:02 suriksarkisyan

This issue is stale because it has been open 7 days with no activity. Remove stale label or comment or this will be closed in 5 days.

github-actions[bot] avatar Feb 14 '24 01:02 github-actions[bot]

This issue was closed because it has been stalled for 5 days with no activity.

github-actions[bot] avatar Feb 19 '24 01:02 github-actions[bot]

@suriksarkisyan any news? Issue got closed automatically now.

Ralph1300 avatar Feb 19 '24 07:02 Ralph1300

@suriksarkisyan any news? Issue got closed automatically now.

We reopened this issue. It's still in progress. We will try to fix it in the next release. And could you please give me some examples of usage of our properties code?

suriksarkisyan avatar Feb 19 '24 09:02 suriksarkisyan