PostHog / PostHog/posthog

Bug: Annotation badges misrender on insights with wide date ranges

Open
#53,676 0 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

bug feature/dashboards team/product-analytics
Dominant language
Python
Stars
39.9k
Forks
3.4k
Avg merge
6h 51m
Merged PRs (30d)
232

Description

Bug Description

Bug description

Please describe.
Annotations are inconsistent depending on the time range
certain date ranges seemingly add annotations unexpectedly , some remove annotations unexpectedly, Annotations are being forced to the start or end of the month, instead of appearing on their correct dates - or they are randomly placed on the line, but not relative to the date of the annotation.

How to reproduce

  1. Open an insight that includes one or more annotations with specific dates (e.g. in March).
  2. Switch between different date ranges.
  3. Observe the annotations displayed on the chart
  4. Hover over the annotations to inspect their details
  5. Notice that annotations are sometimes positioned at the start or end of the month or randomly but, never their actual dates.

Additional context

From: https://posthoghelp.zendesk.com/agent/tickets/54763 (moved to PostHog: https://us.posthog.com/project/2/support/tickets/56879)

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

Start by reproducing the issue in an insight with dated annotations, switching across wide and narrow date ranges and checking the hover details. Trace how the insight chart maps annotation dates to positions; done means every annotation remains on its actual date and appears consistently across the tested ranges.

Written by the indexing model from the issue text.

Assessment

Domain
analytics, frontend
Issue type
Bug
Difficulty
3/5
Estimated time
1-2 days
Activity status
Quiet
Clarity
Mostly clear
Newbie friendliness
45/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.