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

If the description is empty, the field itself will disappear when I run dbt-osmosis yaml refactor #214

Open
syou6162 opened this issue Feb 17, 2025 · 5 comments

Comments

@syou6162
Copy link
Contributor

If the description is an empty string, running dbt-osmosis yaml refactor will cause the description field itself to disappear.

For example, if you run dbt-osmosis yaml refactor on the following yaml,

version: 2
models:
  - name: my_model
    columns:
      - name: example_column
        description: ""
        data_type: STRING

it will become

version: 2
models:
  - name: my_model
    columns:
      - name: example_column
        data_type: STRING

It is possible to add the description field manually, but if a human adds the description field each time, the following problems will occur.

  • The order in which the description properties are added will differ depending on the person
    • If you are running dbt-osmosis in CI/CD, the order of the description properties may change, making it difficult to understand the differences
    • If dbt-osmosis retains the description properties with empty characters, this problem will be less likely to occur

Prior to dbt-osmosis v1, even if the description was empty, the field itself was retained, so I think it would be good to have an option to reproduce that behavior.

@hugohahn009
Copy link

+1

4 similar comments
@niccomassei
Copy link

+1

@imlaf
Copy link

imlaf commented Feb 21, 2025

+1

@AlexLA92
Copy link

+1

@barthichop
Copy link

+1

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

No branches or pull requests

6 participants