amplitude / Amplitude-iOS

Native iOS/tvOS/macOS SDK
MIT License
301 stars 192 forks source link

Data race in -[AMPIdentifyInterceptor transferInterceptedIdentify] #460

Open charleslima opened 1 year ago

charleslima commented 1 year ago

Current Behavior

Found a data race warning in [AMPIdentifyInterceptor transferInterceptedIdentify]

datarace

Steps to Reproduce

  1. Enable Thread Sanitizer in target's scheme
  2. Run the app and see the warning

Environment

Mercy811 commented 1 year ago

Hi @charleslima, I turned Thread Sanitizer on as the following screenshots. However, I didn't see a data race warning when running the app. Is there anything else you set up?

I can see there is a data race as transferInterceptedIdentify rans on a background queue. I will investigate more on this and keep you updated. Also we are deprecating iOS SDK gradually and will GA Swift SDK in about two weeks. As we are having a high volume of support tickets right now you could also try the Swift SDK.

image image