dbt-labs / dbt-labs/dbt-autofix

Adjust deprecations behaviour for projects on dbt <=v1.9

Open
#239 1 comment 0 reactions 0 assignees View on GitHub
Dominant language
Python
Stars
88
Forks
19
Avg merge
1d 1h
Merged PRs (30d)
13

Description

## Summary (enhancement)

I've left the title intentionally vague to avoid an [XY problem](https://en.wikipedia.org/wiki/XY_problem) 😄

I love this tool, and I've been using it liberally on several of the dbt projects that I work on! (I'm a consultant and work across several clients)

However, I recently ran the `deprecations` command on a dbt project which is still on dbt v1.9 (I know [this goes EOL in under two weeks](https://docs.getdbt.com/docs/dbt-versions/core#latest-releases)) and it happily changed all the tests to use the `arguments` attribute, even though that attribute does not exist in dbt v1.9

This is **totally user error on my behalf**, but it would be awesome if the CLI could identify that I was on an older version of dbt and do something different to not break the YAML

I'm thinking either:

1. Warn me (and not run?) so that I know to update my dbt version first
2. Only run fixes appropriate for the current dbt version (e.g. the `move_custom_configs_to_meta_sql` refactor is fine for dbt v1.9)

Since v1.9 is going EOL very soon, I don't think (2) is worth the effort, but just mentioning it anyway in case there is interest in it 🤔

Would throwing a warning on EOL dbt versions be an appropriate behaviour for this tool?

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.