Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Expectation suite not found #39

Closed
pixie79 opened this issue Sep 27, 2021 · 1 comment
Closed

Expectation suite not found #39

pixie79 opened this issue Sep 27, 2021 · 1 comment

Comments

@pixie79
Copy link

pixie79 commented Sep 27, 2021

Hi

I am getting the following error in the logs when trying to run my expectations via airflow.

great_expectations.exceptions.exceptions.DataContextError: expectation_suite accounts not found

import os
import airflow
from airflow import DAG
from great_expectations_provider.operators.great_expectations import GreatExpectationsOperator


default_args = {
  'dir': '/project/great_expectations',
  'start_date': airflow.utils.dates.days_ago(1),
  'profiles_dir': '/home/airflow/.dbt/',
  'catchup': False
}


with DAG(dag_id='accounts_great_expectations', default_args=default_args, schedule_interval='@daily') as dag:
    accounts = GreatExpectationsOperator(
        task_id='accounts',
        expectation_suite_name='accounts',
        data_context_root_dir='/project/great_expectations',
        batch_kwargs={
            'table': 'raw_accounts',
            'datasource': 'fusioncell_local'
        },
        dag=dag
    )

  accounts_great_expectations

It can find the great_expectation.yml file fine though which in /project/great_expectations and my expectations are in a directory one below that called expectations??

Thanks

@pixie79
Copy link
Author

pixie79 commented Sep 27, 2021

its ok, i found the issue was the name of the expectations was not as expected.

@pixie79 pixie79 closed this as completed Sep 27, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant