Skip to content

Conversation

@mydea
Copy link
Member

@mydea mydea commented Aug 7, 2023

This delays adding the internal replay logging breadcrumbs to the next tick, to avoid race conditions on initial logs where replay may not be initialized yet.

With this, you should get proper log breadcrumbs in a replay for itself:

[Replay] Created new session 00:00
[Replay] Starting replay in session mode 00:00

@mydea mydea added the Package: replay Issues related to the Sentry Replay SDK label Aug 7, 2023
@mydea mydea requested a review from billyvg August 7, 2023 09:36
@mydea mydea self-assigned this Aug 7, 2023
`[Replay] Session duration (${Math.floor(duration / 1000)}s) is too ${
tooShort ? 'short' : 'long'
}, not sending replay.`,
this._options._experiments.traceInternals,
Copy link
Member Author

Choose a reason for hiding this comment

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

Also noticed this, missed this in the refactor.

Copy link
Member

Choose a reason for hiding this comment

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

I might have messed this up when rebasing #8716, sorry!

Copy link
Member Author

Choose a reason for hiding this comment

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

no big deal either way, it's just internal logging ;)

`[Replay] Session duration (${Math.floor(duration / 1000)}s) is too ${
tooShort ? 'short' : 'long'
}, not sending replay.`,
this._options._experiments.traceInternals,
Copy link
Member

Choose a reason for hiding this comment

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

I might have messed this up when rebasing #8716, sorry!

@mydea mydea merged commit a0290b9 into develop Aug 7, 2023
@mydea mydea deleted the fn/internal-logging branch August 7, 2023 11:14
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Package: replay Issues related to the Sentry Replay SDK

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants