<@U088WCP3B4P> Data Engineers need to dbt elementa...
# ask-elementary-ai
s
@kapa.ai Data Engineers need to dbt elementary package warnings resolved so we can upgrade Description 11:4`3:22 [WARNING]: Installed package 'elementary' is overriding the built-in`
materialization 'test'. Overrides of built-in materializations from installed
packages will be deprecated in future versions of dbt. Please refer to <https://d>
<http://ocs.getdbt.com/reference/global-configs/legacy-behaviors#require_explicit_packag|ocs.getdbt.com/reference/global-configs/legacy-behaviors#require_explicit_packag>
e_overrides_for_builtin_materializations for detailed documentation and
suggested workarounds.
Behavior changes | dbt Developer Hub how to fix this warning i have set the flag to true and how to define the materialization to override?
k
A message from kapa.ai
The warning you are seeing:
Copy code
[WARNING]: Installed package 'elementary' is overriding the built-in materialization 'test'. Overrides of built-in materializations from installed packages will be deprecated in future versions of dbt.
is expected when using the Elementary dbt package with dbt 1.7+ and especially 1.8+, due to changes in how dbt handles materialization overrides by packages. ### How to Fix or Suppress the Warning 1. Set the Required Flag in
dbt_project.yml
For dbt 1.8 and above, you must explicitly allow packages to override built-in materializations by adding the following to your `dbt_project.yml`:
Copy code
yaml flags:   require_explicit_package_overrides_for_builtin_materializations: false
This flag is required for Elementary to function correctly (e.g., to collect failed row samples and counts for dbt tests). However, **setting this flag will not suppress the warning**—it only ensures that Elementary continues to work as intended. The warning will remain until dbt and Elementary provide a more permanent solution. You can safely ignore the warning for now, as recommended by the Elementary team. They are working with dbt on a long-term fix [[Elementary Docs: Quickstart](https://docs.elementary-data.com/oss/quickstart/quickstart-cli-package#step-by-step%3A-install-elementary-dbt-package)]. 2. Suppressing the Warning Currently, there is no official way to fully suppress this warning in dbt 1.8+—the flag only enables the override, it does not silence the message. If you use
--warn-error
, you may want to temporarily remove it to avoid false positives, as suggested by community members [[Slack thread](https://slack.com/archives/C02CTC89LAX/p1715870116624699)]. 3. Defining Your Own Materialization Override If you want to override the
test
materialization yourself (for example, to customize or bypass Elementary's override), you can define a custom materialization in your own project. Here’s an example from the community:
Copy code
jinja {% materialization test, default %}   {% set result = elementary.materialize_test(dbt.materialization_test_default) %}   {% do return(result) %} {% endmaterialization %}  {% materialization test, adapter="snowflake" %}   {%- if dbt.materialization_test_snowflake -%}     {% set materialization_macro = dbt.materialization_test_snowflake %}   {%- else -%}     {% set materialization_macro = dbt.materialization_test_default %}   {%- endif -%}   {% set result = elementary.materialize_test(materialization_macro) %}   {% do return(result) %} {% endmaterialization %}
This approach is advanced and only needed if you have a specific reason to override Elementary’s behavior [[Slack thread](https://slack.com/archives/C02CTC89LAX/p1722858974369239)]. --- Summary: - Add
require_explicit_package_overrides_for_builtin_materializations: false
to your
dbt_project.yml
. - The warning will persist, but Elementary will work as expected. - Suppression of the warning is not currently possible; ignore it until a permanent fix is released. - Only define your own materialization override if you have a specific need. For more details, see the [Elementary documentation](https://docs.elementary-data.com/oss/quickstart/quickstart-cli-package#step-by-step%3A-install-elementary-dbt-package) and [related Slack discussions](https://slack.com/archives/C02CTC89LAX/p1715016357916139).