-
-
Notifications
You must be signed in to change notification settings - Fork 306
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Wrong value in "In Foreground" for every sentry event #3991
Labels
Comments
That's a good catch thanks. The culprit is here sentry-cocoa/Sources/Sentry/SentryClient.m Lines 633 to 635 in 2b9e267
This is an easy fix. |
7 tasks
philipphofmann
pushed a commit
that referenced
this issue
May 23, 2024
Replaced source of truth for app state from SentryAppStateManager instance to SentryUIApplication. Fixes GH-3991
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Platform
iOS
Environment
Develop
Installed
CocoaPods
Version
8.24.0
Did it work on previous versions?
I don't know. We are starting at this version.
Steps to Reproduce
When app enters background and foreground, the context[@"app"][@"in_foreground"] field is wrong in every event.
The value seems to remain the same value no matter it is YES or NO since app starts.
As I debug the codes, this issue seems to come from LN 634 in SentryClient.m: SentryAppState *appState = [manager loadPreviousAppState];
Expected Result
The value of context[@"app"][@"in_foreground"] field is correct when app enters background and foreground.
Actual Result
The value seems to remain the same value no matter it is YES or NO since app starts.
Are you willing to submit a PR?
No
The text was updated successfully, but these errors were encountered: