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

The operator wouldn't recognize profiles_dir if it finds profile.yml in the project_dir #133

Open
utrivedi15five opened this issue Apr 1, 2024 · 1 comment

Comments

@utrivedi15five
Copy link

As per the title, the profiles.yml is directly loaded from the project_dir if found and it ignores the profiles_dir. I have different target name in profiles.yml that live under /User/username/.dbt/ and I get error saying the target is not in the list, with list of targets from profiles.yml in /path/to/my/dbt/project/

 DbtRunOperator(
        task_id="dbt_run_hourly",
        project_dir="/path/to/my/dbt/project/",
        profiles_dir="/User/username/.dbt/",
        select=["+tag:hourly"],
        target="development",
        profile="my-project",
        full_refresh=True,
    )
@utrivedi15five
Copy link
Author

https://github.com/tomasfarias/airflow-dbt-python/blob/master/airflow_dbt_python/hooks/dbt.py#L400

probably the culprit. It should check if profiles_dir has been specified and if yes then continue reading the profiles_dir

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