calogica / dbt-expectations

Port(ish) of Great Expectations to dbt test macros
https://calogica.github.io/dbt-expectations/
Apache License 2.0
1.06k stars 130 forks source link

Warning: the `length` macro is now provided in dbt Core #213

Closed adamcunnington-mlg closed 1 year ago

adamcunnington-mlg commented 1 year ago

We use this test; https://github.com/calogica/dbt-expectations#expect_column_value_lengths_to_equal

Whenever we use it, we get this warning:

18:02:45  Warning: the `length` macro is now provided in dbt Core. It is no longer available in dbt_utils and backwards compatibility will be removed in a future version of the package. Use `length` (no prefix) instead. The mlg_apollo_data_prod.dbt_expectations_source_expect_column_value_lengths_to_equal_... model triggered this warning.

We couldn't quite work out if DBT was telling us to use a new generic test instead of this dbt expectations test OR if the test by dbt_expectations should be updated to accommodate some deprecated functionality / change. We think the latter but please advise if we are misunderstanding. It's confusing because this test doesn't use anything from dbt_utils (that we can see).

clausherther commented 1 year ago

Hi @adamcunnington-mlg, I think that's still a parsing issue in dbt-utils. They're working on a fix. There's nothing to do on your end w/r/t the test and the test should work as intended. In dbt-expectations, we removed dependencies on deprecated dbt-utils functions a couple of versions ago, so make sure you're on the latest version. Thanks!

adamcunnington-mlg commented 1 year ago

Thanks!