-
Notifications
You must be signed in to change notification settings - Fork 15
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
bug/issue-type #108
bug/issue-type #108
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@fivetran-catfritz I just reviewed and really like your updates! I think the improvements you made to the conditional and for loop logic really help make this model more robust and scalable. I also was able to validate the changes locally as well as using your validation guide. Lastly, knowing that the customer confirmed it works on their end makes me comfortable with these changes. However, before approving I did have one question regarding the need for the else statements. The one comment should also apply to all other conditional updates.
Finally, this is a somewhat similar update to the components update we made a while ago. Do you know if there are any other custom fields that may need a similar update in the future? The updates of those would be out of scope for this ticket, but generally curious if we should create tickets for those proactively.
{% elif col.name|lower not in ['issue_day_id', 'issue_id', 'valid_starting_on', 'components'] %} | ||
, coalesce(pivoted_daily_history.{{ col.name }}, most_recent_data.{{ col.name }}) as {{ col.name }} | ||
|
||
{% else %}{% endif %} |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Is there a reason the else is essentially doing nothing here? Should the previous elif be an else instead?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
It seems this behavior exists for all the other conditionals in this PR. What are your thoughts on the else presence and if we should change the final elif to an else or if the else is not needed at all?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Or is this specific and dependent on each conditional use case in the model?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I had included them because I thought not having them was causing an error I was getting at the time, but I just tried taking all the else
s out, and there are no errors, so yes I agree they're pointless and have removed!
@fivetran-joemarkiewicz Thanks for reviewing! I have pushed the updates to remove the However now that I think of this more, I'm still a little uncertain about what they are supposed to display. I tested out some additional fields like |
@fivetran-catfritz yup this is what I was leaning towards with my probing question around if other custom fields need a similar update. The ultimate goal of this You can see that this is not the case for fields that do not have their own tables synced via the connector. Here is an example of my including a field that has a FK (shows as and ID) and one that does not. Notice how |
Thanks @fivetran-joemarkiewicz that makes sense now. I found this issue already exists, so I'll add comments with more detail of what we found this round. I would say this is ready for re-review now too! |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@fivetran-catfritz thanks for making the updates and contributing to the FR to expand the package to perform the same updates here for the other field types. This looks good to go from my point of view!
PR Overview
This PR will address the following Issue/Feature: #107
This PR will result in the following new package version:
Please detail what change(s) this PR introduces and any additional information that should be known during the review of this PR:
Updated the
jira__daily_issue_field_history
model to make sureissue_type
values are correctly joined into the downstream issue models. This applied only ifissue type
is leveraged within theissue_field_history_columns
variable.Reorganized some of the logic in
jira__daily_issue_field_history
so that the for loops run less often and used nested conditionals.PR Checklist
Basic Validation
Please acknowledge that you have successfully performed the following commands locally:
dbt run –vars (if applicable)Before marking this PR as "ready for review" the following have been applied:
Detailed Validation
Please acknowledge that the following validation checks have been performed prior to marking this PR as "ready for review":
Standard Updates
Please acknowledge that your PR contains the following standard updates:
DECISIONLOG updates have been updated (if applicable)Appropriate yml documentation has been added (if applicable)dbt Docs
Please acknowledge that after the above were all completed the below were applied to your branch:
If you had to summarize this PR in an emoji, which would it be?
💃