Skip to content
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

fix: Duplicate crashed sessions #961

Merged
merged 2 commits into from
Aug 26, 2024

Conversation

timfish
Copy link
Collaborator

@timfish timfish commented Aug 17, 2024

Closes #941. Maybe also #931 and #895.

I re-read through all the Sentry SDK development docs around sessions and found this:

A session can exist in two states: in progress or terminated. A terminated session must not receive further updates. exited, crashed and abnormal are all terminal states. When a session reaches this state the client must not report any more session updates or start a new session.

The Electron SDK was not following this as it was sending further updates after the initial crashed session was sent. I would not have expected these updates to be counted as new sessions since the sid doesn't change and init is never true more than once.

Make no assumptions and read the docs thoroughly!

Copy link
Member

@Lms24 Lms24 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Good catch! I had no idea about this either but TIL

@timfish timfish merged commit 0cd436b into getsentry:master Aug 26, 2024
34 checks passed
@timfish timfish deleted the fix/multiple-sessions branch September 10, 2024 09:42
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

The crash count doesn't match
2 participants