fix: screen events and autocapture should ignore keyboard window #269
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
💡 Motivation and Context
Original thread: https://posthog.slack.com/archives/C0113360FFV/p1733238766585229
Ticket: https://posthoghelp.zendesk.com/agent/tickets/21072
Problem
It seems that we were unintentionally capturing view controllers belonging to the keyboard window when sending
$screen
events. While this might not be a significant issue under normal circumstances, for applications that are message- or form-heavy, this behavior could result in inflated autocapture event volumes.Fix
$autocapture
events + some minor improvements💚 How did you test it?
Sample project
📝 Checklist