Skip to content

Conversation

@KSDaemon
Copy link
Member

@KSDaemon KSDaemon commented May 5, 2025

Cube expects the underlying data source connection to be using UTC as the session timezone (where it is applicable), or expects date_time functions (like now()) to return time in UTC. DateRange Build Start/End queries were parsed incorrectly, for non-UTC timezones this leads to incorrect partitions being rebuilt. This PR fixes that.

Check List

  • Tests have been run in packages where changes made if available
  • Linter has been run for changed code
  • Tests for the changes have been added if not covered yet
  • Docs have been added / updated if required

@codecov
Copy link

codecov bot commented May 5, 2025

Codecov Report

Attention: Patch coverage is 88.88889% with 1 line in your changes missing coverage. Please review.

Project coverage is 57.47%. Comparing base (8cc6346) to head (ee08700).
Report is 11 commits behind head on master.

Files with missing lines Patch % Lines
...y-orchestrator/src/orchestrator/PreAggregations.ts 66.66% 1 Missing ⚠️
Additional details and impacted files
@@            Coverage Diff             @@
##           master    #9543      +/-   ##
==========================================
- Coverage   57.50%   57.47%   -0.04%     
==========================================
  Files         165      165              
  Lines       13504    13517      +13     
  Branches     2278     2278              
==========================================
+ Hits         7766     7769       +3     
- Misses       5430     5443      +13     
+ Partials      308      305       -3     
Flag Coverage Δ
cube-backend 57.47% <88.88%> (-0.04%) ⬇️

Flags with carried forward coverage won't be shown. Click here to find out more.

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.
  • 📦 JS Bundle Analysis: Save yourself from yourself by tracking and limiting bundle sizes in JS merges.

@KSDaemon KSDaemon marked this pull request as ready for review May 5, 2025 21:03
@KSDaemon KSDaemon requested review from a team as code owners May 5, 2025 21:03
@KSDaemon KSDaemon merged commit 20dd8ad into master May 7, 2025
59 checks passed
@KSDaemon KSDaemon deleted the fix/refresh-in-future branch May 7, 2025 17:23
marianore-muttdata pushed a commit to MuttData/cube that referenced this pull request Jun 17, 2025
…rt/end queries (cube-js#9543)

* code polish

* Refactor a bit

* Add tests for daily partitions

* refactor parseLocalDate to use UTC during parsing and then input timezone for result shifting

* tests

* fix tests

* fix test

* another test fix
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants