<@U088WCP3B4P> I am trying to upgrade to a newer v...
# ask-elementary-ai
f
@kapa.ai I am trying to upgrade to a newer version of elementary, and running
dbt run --select elementary
as recommended in the docs, but I am getting
The selection criterion 'elementary' does not match any nodes
. Any ideas on what is going wrong?
k
A message from kapa.ai
The error message
The selection criterion 'elementary' does not match any nodes
when running
dbt run --select elementary
usually means that dbt cannot find any models or resources named "elementary" in your current project context. Based on the knowledge sources, here are the most common causes and solutions: 1. Elementary Package Not Installed or Not Referenced Properly - Ensure that the Elementary dbt package is correctly listed in your
packages.yml
file. - After updating
packages.yml
, run
dbt deps
to install the package. - Confirm that the
dbt_packages/elementary
directory exists and contains the expected models and macros. [See example](https://slack.com/archives/C02CTC89LAX/p1703263929892129) 2. Wrong dbt Target or Environment - If you have multiple targets (e.g., dev, prod), make sure you are running the command on the correct target where Elementary is enabled. - For example, if Elementary is only enabled on the
prod
target, use:
Copy code
dbt run --select elementary --target=prod
[See example](https://slack.com/archives/C02CTC89LAX/p1687776269471449) 3. Elementary Models Disabled via Configuration - Check your
dbt_project.yml
for any configuration that disables Elementary models, such as:
Copy code
yaml      models:        elementary:          +enabled: "{{ var('cli_enable_elementary', False) }}"
- If you use a variable to enable Elementary, make sure to set it to
True
when running the command:
Copy code
dbt run --select elementary --vars '{"cli_enable_elementary": true}'
[See example](https://slack.com/archives/C02CTC89LAX/p1680689840547609) 4. Version Mismatch or Incomplete Upgrade - If you recently upgraded, ensure both the Python and dbt package versions of Elementary are compatible and up to date. - After updating, always run
dbt deps
and then
dbt run --select elementary
. [See example](https://slack.com/archives/C02CTC89LAX/p1699010103609409) If you have checked all the above and still encounter the issue, double-check your
dbt_project.yml
,
packages.yml
, and the output of
dbt deps
. If Elementary is disabled or not installed in your current environment/target, dbt will not find any nodes to run. Let me know if you need help reviewing your configuration files!