PostHog / PostHog/posthog

Migrated events do not have $groups property set correctly

Open
#48,832 0 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

bug
Dominant language
Python
Stars
39.9k
Forks
3.4k
Avg merge
6h 51m
Merged PRs (30d)
232

Description

Bug Description
  • User cannot filter dashboard by group. Wants to ideally filter by group name.
  • User imported historical events that did not get properly fed into the database.
  • When filtering by group name in the dashboard, it only applies to the new events, not the historical ones.

Some of the migrated events did not populate $group_0 field in the events, as they have properties.groups set instead of properties.$groups.

Zendesk tickets:

Debug info
- [ ] PostHog Cloud, Debug information: [please copy/paste from https://us.posthog.com/settings/project-details#variables or https://eu.posthog.com/settings/project-details#variables]
- [ ] PostHog Hobby self-hosted with `docker compose`, version/commit: [please provide]
- [ ] PostHog self-hosted with Kubernetes (deprecated, see [`Sunsetting Kubernetes support`](https://posthog.com/blog/sunsetting-helm-support-posthog)), version/commit: [please provide]

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

No file, test, or entry point is named. Start by tracing how migrated events store properties.groups versus properties.$groups, then verify how dashboard group filters read those properties. Done means historical events populate $group_0 consistently and filtering by group name includes both historical and new events.

Written by the indexing model from the issue text.

Assessment

Tech stack
python
Domain
analytics
Issue type
Bug
Difficulty
4/5
Estimated time
3-5 days
Activity status
Stale
Clarity
Needs clarification
Newbie friendliness
45/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.