You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
View Users on a chart point returns nobody for weekly charts and for organizations outside UTC #654
On a time-series chart, clicking a point and choosing View Users often shows "No users found" while the chart shows a non-zero count for that point.
Weekly charts: every point comes back empty, in every timezone.
Organizations outside UTC: hour points come back empty, and day and month points match the wrong bucket (empty, or missing users near the edge of the period).
Steps to reproduce
Open a report with a line chart and interval Week.
Click any point with a count above 0 and choose View Users.
The modal says "No users found".
For the timezone case, set the organization's timezone to America/New_York and do the same on an Hour chart.
Root cause
chartBucketProfilesQuery (packages/core/src/modules/chart/src/sql.ts, bucketEquals) doesn't match how the chart buckets its points:
The chart builds weeks with toStartOfWeek(created_at, 1, tz), so weeks start on Monday. The drill-down uses toStartOfWeek(toDateTime(created_at)), which uses mode 0, so weeks start on Sunday. A Sunday week start never equals the Monday date the chart sends back.
The chart runs with the organization's timezone as session_timezone. getChartBucketProfiles calls runQuery without a timezone, so the drill-down buckets in UTC while the point's date is in the organization's timezone.
Expected behavior
View Users returns the users behind the point, with the same count the chart shows, for every interval and timezone.
Activity