-
Notifications
You must be signed in to change notification settings - Fork 111
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
Description doesn't inherit code blocks when using upstream_descriptions. #111
Comments
Absolutely would love this feature. However, I'm afraid that the inherited description comes from the I don't know if it would be possible to obtain what you're looking for. Not using pure dbt macros anyway. |
This issue has been marked as Stale because it has been open for 180 days with no activity. If you would like the issue to remain open, please comment on the issue or else it will be closed in 7 days. |
Although we are closing this issue as stale, it's not gone forever. Issues can be reopened if there is renewed community interest. Just add a comment to notify the maintainers. |
This call is coming from inside the house (dbt internal data team) and I also think this functionality would be incredible as I carry dozens of field descriptions from one rev rec model through the next five. |
Hi! Would love to inherit doc blocks instead of the description itself. Any chance of this being worked on in the near future? |
Describe the bug
When using the
generate_model_yaml
functionality withupstream_descriptions
it seems that the generated yaml file doesn't use the exact yaml description from upstream. Instead it uses the "compiled" description. This is a problem when using code blocks and goes directly against the reason to use code blocks.Steps to reproduce
You can skip A by using the attached zip file which contains the necessary files.
reproduce-files.zip
A. We need the following steps (1->3) to setup a demo environment.
dummy_model.sql
with the following content:dummy_model.yml
with the following content:dummy_model.md
with the following content:second_dummy_model.sql
with the following content:B. Now we can execute the following commands to generate the model yaml (using upstream descriptions).
dbt compile dbt run-operation generate_model_yaml --args '{"model_names": ["second_dummy_model"], "upstream_descriptions": true}'
Expected results
The generated yaml file should contain the same column descriptions as the upstream model. In this case, this would need to be
"{{ doc('dummy_model__first_column') }}"
.Full expected result would be:
Actual results
However, the result is the "compiled" description as you can see below:
Screenshots and log output
Not required.
System information
Not required.
Are you interested in contributing the fix?
Certainly, but I can't find a way to get the original description. Couldn't find it in the used graph object myself, so hopefully someone can lend a hand here! Asked it in the
#advice-dbt-for-power-users
channel on Slack as well with this post.The text was updated successfully, but these errors were encountered: