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

feat(insights): hide "other" breakdown #19359

Merged
merged 34 commits into from
Dec 19, 2023
Merged
Show file tree
Hide file tree
Changes from 20 commits
Commits
Show all changes
34 commits
Select commit Hold shift + click to select a range
e4d52b8
feat(trends): support numeric breakdowns
mariusandra Dec 12, 2023
13c4e65
fix test
mariusandra Dec 12, 2023
c8dd99d
feat(insights): hide "other" in breakdowns
mariusandra Dec 14, 2023
a831bb2
Merge branch 'master' into breakdown-hide-other
mariusandra Dec 15, 2023
6838e36
show in the interface
mariusandra Dec 15, 2023
d2fbce4
fix
mariusandra Dec 15, 2023
54730e6
fix schema
mariusandra Dec 15, 2023
812c1c5
fix filter
mariusandra Dec 15, 2023
2789b0a
support nulls in breakdown
mariusandra Dec 18, 2023
b14ba9f
Update query snapshots
github-actions[bot] Dec 18, 2023
5b94e42
Update query snapshots
github-actions[bot] Dec 18, 2023
402d8c2
Update query snapshots
github-actions[bot] Dec 18, 2023
f012733
Update query snapshots
github-actions[bot] Dec 18, 2023
609afbc
Update query snapshots
github-actions[bot] Dec 18, 2023
45b97c3
less changed snapshots!
mariusandra Dec 18, 2023
4dfc9eb
Merge remote-tracking branch 'origin/breakdown-hide-other' into break…
mariusandra Dec 18, 2023
4b4d026
swap to a switch
mariusandra Dec 18, 2023
a220d1f
fix tests
mariusandra Dec 18, 2023
493c44f
fix tests
mariusandra Dec 18, 2023
c5f16c4
Update query snapshots
github-actions[bot] Dec 18, 2023
b4cb3d4
Merge branch 'master' into breakdown-hide-other
mariusandra Dec 19, 2023
e93a213
label typo
mariusandra Dec 19, 2023
6494443
breakdown other
mariusandra Dec 19, 2023
186c772
Update UI snapshots for `webkit` (2)
github-actions[bot] Dec 19, 2023
3a02fa0
Update UI snapshots for `chromium` (2)
github-actions[bot] Dec 19, 2023
08af3a8
Update UI snapshots for `chromium` (1)
github-actions[bot] Dec 19, 2023
aba7755
Update UI snapshots for `chromium` (1)
github-actions[bot] Dec 19, 2023
cb3860e
move to breakdown tag menu
mariusandra Dec 19, 2023
1a0e7cc
Merge remote-tracking branch 'origin/breakdown-hide-other' into break…
mariusandra Dec 19, 2023
1c8e73d
Update UI snapshots for `webkit` (2)
github-actions[bot] Dec 19, 2023
f6fe702
Update UI snapshots for `chromium` (2)
github-actions[bot] Dec 19, 2023
f2485d5
cleanup
mariusandra Dec 19, 2023
fb89d8d
Merge branch 'master' into breakdown-hide-other
mariusandra Dec 19, 2023
6dc6d97
Merge branch 'breakdown-hide-other' of github.com:PostHog/posthog int…
mariusandra Dec 19, 2023
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1,104 changes: 523 additions & 581 deletions ee/clickhouse/queries/funnels/test/__snapshots__/test_funnel.ambr

Large diffs are not rendered by default.

424 changes: 204 additions & 220 deletions ee/clickhouse/queries/test/__snapshots__/test_breakdown_props.ambr

Large diffs are not rendered by default.

Original file line number Diff line number Diff line change
Expand Up @@ -13,19 +13,17 @@
# name: ClickhouseTestExperimentSecondaryResults.test_basic_secondary_metric_results.1
'
/* user_id:0 request:_snapshot_ */
SELECT groupArray(value)
FROM
(SELECT replaceRegexpAll(JSONExtractRaw(properties, '$feature/a-b-test'), '^"|"$', '') AS value,
count(*) as count
FROM events e
WHERE team_id = 2
AND event = '$pageview'
AND toTimeZone(timestamp, 'UTC') >= toDateTime('2020-01-01 00:00:00', 'UTC')
AND toTimeZone(timestamp, 'UTC') <= toDateTime('2020-01-06 00:00:00', 'UTC')
GROUP BY value
ORDER BY count DESC, value DESC
LIMIT 25
OFFSET 0)
SELECT replaceRegexpAll(JSONExtractRaw(properties, '$feature/a-b-test'), '^"|"$', '') AS value,
count(*) as count
FROM events e
WHERE team_id = 2
AND event = '$pageview'
AND toTimeZone(timestamp, 'UTC') >= toDateTime('2020-01-01 00:00:00', 'UTC')
AND toTimeZone(timestamp, 'UTC') <= toDateTime('2020-01-06 00:00:00', 'UTC')
GROUP BY value
ORDER BY count DESC, value DESC
LIMIT 25
OFFSET 0
'
---
# name: ClickhouseTestExperimentSecondaryResults.test_basic_secondary_metric_results.2
Expand All @@ -51,13 +49,13 @@
CROSS JOIN
(SELECT breakdown_value
FROM
(SELECT ['control', 'test', 'ablahebf', ''] as breakdown_value) ARRAY
(SELECT ['control', 'test', 'ablahebf', '$$_posthog_breakdown_null_$$'] as breakdown_value) ARRAY
JOIN breakdown_value) as sec
ORDER BY breakdown_value,
day_start
UNION ALL SELECT count(*) as total,
toStartOfDay(toTimeZone(toDateTime(timestamp, 'UTC'), 'UTC')) as day_start,
transform(replaceRegexpAll(JSONExtractRaw(properties, '$feature/a-b-test'), '^"|"$', ''), (['control', 'test', 'ablahebf', '']), (['control', 'test', 'ablahebf', '']), '$$_posthog_breakdown_other_$$') as breakdown_value
transform(ifNull(nullIf(replaceRegexpAll(JSONExtractRaw(properties, '$feature/a-b-test'), '^"|"$', ''), ''), '$$_posthog_breakdown_null_$$'), (['control', 'test', 'ablahebf', '$$_posthog_breakdown_null_$$']), (['control', 'test', 'ablahebf', '$$_posthog_breakdown_null_$$']), '$$_posthog_breakdown_other_$$') as breakdown_value
FROM events e
WHERE e.team_id = 2
AND event = '$pageview'
Expand All @@ -76,19 +74,17 @@
# name: ClickhouseTestExperimentSecondaryResults.test_basic_secondary_metric_results.3
'
/* user_id:0 request:_snapshot_ */
SELECT groupArray(value)
FROM
(SELECT array(replaceRegexpAll(JSONExtractRaw(properties, '$feature/a-b-test'), '^"|"$', '')) AS value,
count(*) as count
FROM events e
WHERE team_id = 2
AND event IN ['$pageleave_funnel', '$pageview_funnel']
AND toTimeZone(timestamp, 'UTC') >= toDateTime('2020-01-01 00:00:00', 'UTC')
AND toTimeZone(timestamp, 'UTC') <= toDateTime('2020-01-06 00:00:00', 'UTC')
GROUP BY value
ORDER BY count DESC, value DESC
LIMIT 25
OFFSET 0)
SELECT array(replaceRegexpAll(JSONExtractRaw(properties, '$feature/a-b-test'), '^"|"$', '')) AS value,
count(*) as count
FROM events e
WHERE team_id = 2
AND event IN ['$pageleave_funnel', '$pageview_funnel']
AND toTimeZone(timestamp, 'UTC') >= toDateTime('2020-01-01 00:00:00', 'UTC')
AND toTimeZone(timestamp, 'UTC') <= toDateTime('2020-01-06 00:00:00', 'UTC')
GROUP BY value
ORDER BY count DESC, value DESC
LIMIT 25
OFFSET 0
'
---
# name: ClickhouseTestExperimentSecondaryResults.test_basic_secondary_metric_results.4
Expand Down
Loading
Loading