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(trends): fallback to event data for distinct_ids of personless events #27131

Merged
merged 11 commits into from
Jan 2, 2025

Conversation

thmsobrmlr
Copy link
Contributor

@thmsobrmlr thmsobrmlr commented Dec 23, 2024

Problem

Personless events do not have a person profile. Since we use the person profile to look up distinct_ids in the actor query, these actors appear without distinct_ids:

Screenshot 2024-12-23 at 15 22 42

Changes

This PR adds a fallback to distinct_ids of the underlying events, starting with the trends query. This will need to be implemented for other query types as well.

Screenshot 2024-12-23 at 15 22 35 Screenshot 2024-12-23 at 15 38 48

How did you test this code?

Tested locally. The actors and trend queries have many layers of abstraction, hoping eventual issues will be caught in CI.

@thmsobrmlr thmsobrmlr requested a review from a team December 31, 2024 14:04
@thmsobrmlr thmsobrmlr merged commit 2a06229 into master Jan 2, 2025
92 checks passed
@thmsobrmlr thmsobrmlr deleted the distinct-id-personless-trends branch January 2, 2025 08:53
Copy link

sentry-io bot commented Jan 2, 2025

Suspect Issues

This pull request was deployed and Sentry observed the following issues:

  • ‼️ IndexError: tuple index out of range posthog.tasks.exporter.export_asset View Issue
  • ‼️ IndexError: tuple index out of range posthog.tasks.tasks.process_query_task View Issue

Did you find this useful? React with a 👍 or 👎

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.

2 participants