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

Recognize when loaded_at_field is explicitly set to null #10065

Merged
merged 9 commits into from
May 2, 2024

Conversation

emmyoop
Copy link
Member

@emmyoop emmyoop commented Apr 29, 2024

resolves #9320

Problem

When loaded_at_field is explicitly set to null at the table level, it does not override the source level setting.

Solution

Add logic to recognize when the field is set vs unset.

Checklist

  • I have read the contributing guide and understand what's expected of me
  • I have run this code in development and it appears to resolve the stated issue
  • This PR includes tests, or tests are not required/relevant for this PR
  • This PR has no interface changes (e.g. macros, cli, logs, json artifacts, config files, adapter interface, etc) or this PR has already received feedback and approval from Product or DX
  • This PR includes type annotations for new and modified functions

@cla-bot cla-bot bot added the cla:yes label Apr 29, 2024
Copy link

codecov bot commented Apr 29, 2024

Codecov Report

Attention: Patch coverage is 96.00000% with 1 lines in your changes are missing coverage. Please review.

Project coverage is 88.17%. Comparing base (bcbde3a) to head (797bee6).
Report is 10 commits behind head on main.

Files Patch % Lines
core/dbt/contracts/graph/unparsed.py 92.30% 1 Missing ⚠️
Additional details and impacted files
@@            Coverage Diff             @@
##             main   #10065      +/-   ##
==========================================
- Coverage   88.22%   88.17%   -0.06%     
==========================================
  Files         181      181              
  Lines       22643    22722      +79     
==========================================
+ Hits        19976    20034      +58     
- Misses       2667     2688      +21     
Flag Coverage Δ
integration 85.48% <96.00%> (-0.10%) ⬇️
unit 62.37% <80.00%> (+0.06%) ⬆️

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.

@emmyoop emmyoop changed the title Er/9320 source freshness Recognize when loaded_at_field is explicitly set to null Apr 29, 2024
@emmyoop emmyoop force-pushed the er/9320-source-freshness branch from 6364862 to 0c2e94d Compare May 2, 2024 13:14
@emmyoop emmyoop marked this pull request as ready for review May 2, 2024 13:41
@emmyoop emmyoop requested a review from a team as a code owner May 2, 2024 13:41
@emmyoop emmyoop force-pushed the er/9320-source-freshness branch from 683785d to 797bee6 Compare May 2, 2024 13:49
Copy link
Contributor

@gshank gshank left a comment

Choose a reason for hiding this comment

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

Looks good!

@emmyoop emmyoop merged commit 1bcef62 into main May 2, 2024
63 checks passed
@emmyoop emmyoop deleted the er/9320-source-freshness branch May 2, 2024 14:55
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
2 participants