Skip to content

Fix match_day_of_week for year_over_year comparisons in day and 24h periods#6300

Merged
RobertJoonas merged 1 commit intomasterfrom
fix-year-over-year-comp
May 4, 2026
Merged

Fix match_day_of_week for year_over_year comparisons in day and 24h periods#6300
RobertJoonas merged 1 commit intomasterfrom
fix-year-over-year-comp

Conversation

@RobertJoonas
Copy link
Copy Markdown
Contributor

Changes

Currently, the Last 24h and today periods are not respecting match_day_of_week in year_over_year comparison mode.

For Last 24h it was never implemented. For the today period it used to work before #6205 because it didn't get the special "datetime" treatment (therefore, it fell into the default get_comparison_date_range(%Query{include: %{compare: :year_over_year}} = source_query) function clause, and got maybe_match_day_of_week called on the result).

This PR implements the missing piece and adds tests.

Tests

  • Automated tests have been added

Changelog

  • Does not require a changelog update -- both last 24 hours period and today comparison matching the exact number of hours are part of the current release.

Documentation

  • This change does not need a documentation update

Dark mode

  • This PR does not change the UI

@github-actions
Copy link
Copy Markdown

Preview environment👷🏼‍♀️🏗️
PR-6300

@RobertJoonas RobertJoonas requested a review from zoldar May 4, 2026 07:09
Copy link
Copy Markdown
Contributor

@zoldar zoldar left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM ✨

@RobertJoonas RobertJoonas added this pull request to the merge queue May 4, 2026
Merged via the queue into master with commit dcb92e5 May 4, 2026
23 checks passed
@RobertJoonas RobertJoonas deleted the fix-year-over-year-comp branch May 4, 2026 08:24
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants