-
Notifications
You must be signed in to change notification settings - Fork 95
Open
Labels
bugSomething isn't workingSomething isn't working
Description
Describe the bug - Required
When checking test results in the DQL dashboard, unexpected warnings for data type checks are showing.
Environment - Required
- Tuva project package version (e.g. 0.6.0): 0.15.0
- dbt version (e.g. 1.7):
- dbt type (e.g. dbt cloud or dbt CLI): cli
- Data warehouse (e.g. Snowflake): duckdb
To Reproduce
Steps to reproduce the behavior:
- Run dbt test -s input_layer__medical_claim
- Check results on the dql dashboard
Expected behavior
These warnings do not show up when there is a valid data type.
Screenshots
If applicable, add screenshots to help explain your problem.
Additional context
I blieve the problem is in the else clause in the snippet below, that last parameter should match the wrapper parameter.
{% test expect_column_values_to_be_in_type_list(model, column_name, column_type_list) %}
{% if is_fabric() %}
SELECT COLUMN_NAME
FROM INFORMATION_SCHEMA.COLUMNS
WHERE
TABLE_NAME = '{{ model.name }}'
{% if model.schema %}AND TABLE_SCHEMA = '{{ model.schema }}'{% endif %}
AND DATA_TYPE NOT IN (
{% for column_type in column_type_list %}
'{{ column_type }}'{% if not loop.last %},{% endif %}
{% endfor %}
)
AND COLUMN_NAME = '{{ quote_column(column_name)}}'
{% else %}
{{ dbt_expectations.test_expect_column_values_to_be_in_type_list(model, column_name, column_type) }}
{% endif %}
{% endtest %}```
Metadata
Metadata
Assignees
Labels
bugSomething isn't workingSomething isn't working
Type
Projects
Status
👍 Ready to Pull