-
Notifications
You must be signed in to change notification settings - Fork 1.6k
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
Support null coalescing properties for metric nodes #8700
Support null coalescing properties for metric nodes #8700
Conversation
…re inputs to metrics
… break associated DSI protocol
Codecov ReportPatch coverage:
Additional details and impacted files@@ Coverage Diff @@
## main #8700 +/- ##
==========================================
- Coverage 86.65% 85.31% -1.34%
==========================================
Files 176 176
Lines 25674 25678 +4
==========================================
- Hits 22247 21907 -340
- Misses 3427 3771 +344
Flags with carried forward coverage won't be shown. Click here to find out more.
☔ View full report in Codecov by Sentry. |
The `assert_symmetric` function asserts that dictionaries are mostly equivalent. I say mostly equivalent because it drops keys that are `None`. The issue is that that `join_to_timespine` gets defaulted to `False`, so we have to specify it in the `get_ok_dict` so that they match.
The backport to
To backport manually, run these commands in your terminal: # Fetch latest updates from GitHub
git fetch
# Create a new working tree
git worktree add .worktrees/backport-1.6.latest 1.6.latest
# Navigate to the new working tree
cd .worktrees/backport-1.6.latest
# Create a new branch
git switch --create backport-8700-to-1.6.latest
# Cherry-pick the merged commit of this pull request and resolve the conflicts
git cherry-pick -x --mainline 1 48e9ced7815247d4d429fefba606aae3f77479ba
# Push it to GitHub
git push --set-upstream origin backport-8700-to-1.6.latest
# Go back to the original working tree
cd ../..
# Delete the working tree
git worktree remove .worktrees/backport-1.6.latest Then, create a pull request where the |
* Include 'join_to_timespine` and `fill_nulls_with` in metric fixture * Support `join_to_timespine` and `fill_nulls_with` properties on measure inputs to metrics * Assert new `fill_nulls_with` and `join_to_timespine` properties don't break associated DSI protocol * Add doc for metric null coalescing improvements * Fix unit test for unparsed metric objects The `assert_symmetric` function asserts that dictionaries are mostly equivalent. I say mostly equivalent because it drops keys that are `None`. The issue is that that `join_to_timespine` gets defaulted to `False`, so we have to specify it in the `get_ok_dict` so that they match.
…odes (#8700) (#8773) * Support null coalescing properties for metric nodes (#8700) * Include 'join_to_timespine` and `fill_nulls_with` in metric fixture * Support `join_to_timespine` and `fill_nulls_with` properties on measure inputs to metrics * Assert new `fill_nulls_with` and `join_to_timespine` properties don't break associated DSI protocol * Add doc for metric null coalescing improvements * Fix unit test for unparsed metric objects The `assert_symmetric` function asserts that dictionaries are mostly equivalent. I say mostly equivalent because it drops keys that are `None`. The issue is that that `join_to_timespine` gets defaulted to `False`, so we have to specify it in the `get_ok_dict` so that they match. * Regenerate v10 schema to include null coalescing options
* Include 'join_to_timespine` and `fill_nulls_with` in metric fixture * Support `join_to_timespine` and `fill_nulls_with` properties on measure inputs to metrics * Assert new `fill_nulls_with` and `join_to_timespine` properties don't break associated DSI protocol * Add doc for metric null coalescing improvements * Fix unit test for unparsed metric objects The `assert_symmetric` function asserts that dictionaries are mostly equivalent. I say mostly equivalent because it drops keys that are `None`. The issue is that that `join_to_timespine` gets defaulted to `False`, so we have to specify it in the `get_ok_dict` so that they match.
resolves #8593
Problem
MetricFlow is adding support for null value coalescing (dbt-labs/metricflow#759). In order to use that, dbt-core needs to support the related properties
Solution
Add the properties
join_to_timespine
andfill_nulls_with
(as defined in the related MF and DSI issues: dbt-labs/metricflow#759, dbt-labs/dbt-semantic-interfaces#142) to the metric node definition.Checklist