sentry-cocoa
sentry-cocoa copied to clipboard
Calling `addBreadcrumb` triggers `Main Thread Checker` warning
Platform
iOS
Environment
Develop
Installed
Swift Package Manager
Version
8.26.0
Xcode Version
15.2
Did it work on previous versions?
not sure
Steps to Reproduce
Call SentrySDK.addBreadcrumb() from a background thread
Expected Result
No main thread checker issue is found.
Actual Result
Result
Xcode shows a Main Thread checker warning. The SDK is calling UIKit methods that require Main Thread execution on a background thread.
Logs and screenshots
Main Thread Checker: UI API called on a background thread: -[UIWindow screen]
PID: 45981, TID: 2549765, Thread name: (none), Queue name: com.apple.root.user-initiated-qos.cooperative, QoS: 25
Question
I checked the iOS documentation and it does not mention that breadcrumb should be added from the main thread. Is it an issue from Sentry SDK that needs to be addressed or does it actually recommended to call that method from the main thread ?
Are you willing to submit a PR?
No response