Skip to content

feat: add new granularities - #1701

Open
okrcmaGD wants to merge 1 commit into
gooddata:masterfrom
okrcmaGD:okrc/cq-2758
Open

feat: add new granularities#1701
okrcmaGD wants to merge 1 commit into
gooddata:masterfrom
okrcmaGD:okrc/cq-2758

Conversation

@okrcmaGD

@okrcmaGD okrcmaGD commented Aug 3, 2026

Copy link
Copy Markdown
Contributor

JIRA: CQ-2758
risk: low

Summary by CodeRabbit

  • New Features

    • Added support for second-level date granularity, including seconds, seconds within a minute or day, and minutes within a day.
    • Date filters, timestamp conversion, visualization, pipelines, and data integrations now recognize the expanded granularity options.
  • Bug Fixes

    • Improved timestamp conversion to preserve seconds-level precision.
  • Tests

    • Added coverage for supported date filters and second-precision timestamp conversion.

@coderabbitai

coderabbitai Bot commented Aug 3, 2026

Copy link
Copy Markdown

Review Change Stack

No actionable comments were generated in the recent review. 🎉

ℹ️ Recent review info
⚙️ Run configuration

Configuration used: Organization UI

Review profile: CHILL

Plan: Pro

Run ID: 982f9e66-324a-4f99-a470-3ad6e12886a0

📥 Commits

Reviewing files that changed from the base of the PR and between a8de52a and 736695d.

📒 Files selected for processing (10)
  • packages/gooddata-dbt/src/gooddata_dbt/dbt/base.py
  • packages/gooddata-flexconnect/json_schemas/execution-context/date-granularity.json
  • packages/gooddata-pandas/src/gooddata_pandas/arrow_convertor.py
  • packages/gooddata-pandas/tests/utils/test_utils.py
  • packages/gooddata-pipelines/src/gooddata_pipelines/ldm_extension/input_processor.py
  • packages/gooddata-sdk/src/gooddata_sdk/compute/model/filter.py
  • packages/gooddata-sdk/src/gooddata_sdk/type_converter.py
  • packages/gooddata-sdk/src/gooddata_sdk/visualization.py
  • packages/gooddata-sdk/tests/compute_model/test_date_filters.py
  • packages/gooddata-sdk/tests/test_type_converter.py
🚧 Files skipped from review as they are similar to previous changes (10)
  • packages/gooddata-sdk/src/gooddata_sdk/type_converter.py
  • packages/gooddata-pipelines/src/gooddata_pipelines/ldm_extension/input_processor.py
  • packages/gooddata-pandas/src/gooddata_pandas/arrow_convertor.py
  • packages/gooddata-flexconnect/json_schemas/execution-context/date-granularity.json
  • packages/gooddata-sdk/tests/compute_model/test_date_filters.py
  • packages/gooddata-sdk/tests/test_type_converter.py
  • packages/gooddata-dbt/src/gooddata_dbt/dbt/base.py
  • packages/gooddata-sdk/src/gooddata_sdk/compute/model/filter.py
  • packages/gooddata-sdk/src/gooddata_sdk/visualization.py
  • packages/gooddata-pandas/tests/utils/test_utils.py

📝 Walkthrough

Walkthrough

The change adds second-level and additional day-level date granularities to schemas, registries, SDK mappings, conversion support, documentation, and tests.

Changes

Date granularity support

Layer / File(s) Summary
Granularity contracts and registries
packages/gooddata-flexconnect/..., packages/gooddata-dbt/..., packages/gooddata-pipelines/..., packages/gooddata-sdk/src/gooddata_sdk/compute/model/filter.py
Supported values now include SECOND, SECOND_OF_MINUTE, SECOND_OF_DAY, and MINUTE_OF_DAY across schemas and package registries.
Conversion mappings and validation
packages/gooddata-sdk/src/gooddata_sdk/visualization.py, packages/gooddata-sdk/src/gooddata_sdk/type_converter.py, packages/gooddata-pandas/..., packages/gooddata-sdk/tests/...
SDK and pandas conversion paths support second-level values. Tests cover filter retention and seconds-precision timestamp conversion.

Estimated code review effort: 2 (Simple) | ~10 minutes

Suggested reviewers: lupko, pcerny, hkad98

Poem

A rabbit checks each second’s place,
Through schemas, filters, time, and space.
Timestamps keep their careful beat,
While granularities align neat.
Hop, hop—the tests confirm the trace!

🚥 Pre-merge checks | ✅ 4 | ❌ 1

❌ Failed checks (1 warning)

Check name Status Explanation Resolution
Docstring Coverage ⚠️ Warning Docstring coverage is 16.67% which is insufficient. The required threshold is 80.00%. Write docstrings for the functions missing them to satisfy the coverage threshold.
✅ Passed checks (4 passed)
Check name Status Explanation
Description Check ✅ Passed Check skipped - CodeRabbit’s high-level summary is enabled.
Title check ✅ Passed The title clearly summarizes the main change: adding new date granularities across the SDK.
Linked Issues check ✅ Passed Check skipped because no linked issues were found for this pull request.
Out of Scope Changes check ✅ Passed Check skipped because no linked issues were found for this pull request.

Comment @coderabbitai help to get the list of available commands.

@codecov

codecov Bot commented Aug 3, 2026

Copy link
Copy Markdown

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 78.30%. Comparing base (acfcc1a) to head (736695d).

Additional details and impacted files
@@           Coverage Diff           @@
##           master    #1701   +/-   ##
=======================================
  Coverage   78.30%   78.30%           
=======================================
  Files         271      271           
  Lines       18689    18689           
=======================================
  Hits        14634    14634           
  Misses       4055     4055           

☔ View full report in Codecov by Harness.
📢 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.

JIRA: CQ-2758
risk: low
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.

1 participant