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

Release 1.2.5 #709

Merged
merged 11 commits into from
Nov 23, 2023
Merged

Release 1.2.5 #709

merged 11 commits into from
Nov 23, 2023

Conversation

tatiana
Copy link
Collaborator

@tatiana tatiana commented Nov 23, 2023

Bug fixes

Others

jbandoro and others added 11 commits November 23, 2023 14:33
(cherry picked from commit 709ba44)
Current version, cosmos will got bug `Not found node` because it run
with alias selection as: `--models customers_abc_v1 ` and `--models
customers_abc_v2` .
I propose to parsing node selection in `unique_id` instead of using
`alias` .
So node selection should be: `unique_id.split('.', 2)[2]` , reference to
[function](https://github.com/dbt-labs/dbt-core/blob/main/core/dbt/contracts/graph/node_args.py#L26)
and [resource-details
document](https://docs.getdbt.com/reference/artifacts/manifest-json#resource-details).
In addition, with this change help cosmos also support versioned models
on dbt-core `>=1.5.0` instead `>=1.6.0` as current version.

Cosmos will support dynamic aliases and versioned models

Closes: #636

(cherry picked from commit e23a445)
…ERNETES` (#681)

This PR moves validation of the `profiles_yml_path` to later in the dag
generation process such that additional context can be gathered from
`ExecutionConfig` to avoid failing unnecessarily when the file does not
exist.

Closes: #680
Closes: #656
(cherry picked from commit d28d3df)
To make `on_warning_callback` work with pod operators, we need
to read the logs of the dbt test runs. This is done by ensuring the
pod is kept alive, and `on_success_callback` the log is read and
analysed for warnings.

Afterwards, the pod is cleaned up based on the original settings from
the user.

If `on_warning_callback` is not set, everything stays the way it always
was.

This feature only work with `apache-airflow-providers-cncf-kubernetes >= 7.4.0`.

(cherry picked from commit 0b538a5)
Ignore `WarnErrorOptions` string in stdout from dbt-core, do not treat it
as a failure

Closes: #642
(cherry picked from commit a52d1b7)
After speaking with customers, it looks like it would be more clear to
flag our examples in the dev folder in the README.

Co-authored-by: Julian LaNeve <[email protected]>
(cherry picked from commit 24aa38e)
The example DAG we had declared in our README and index page was
incompatible with the latest versions of Cosmos.

An Astronomer customer reported this, and we didn't realise it because
those code excerpts were not executed.

This PR changes the references to an example DAG run as part of our
integration tests.

As a follow-up, we should try to avoid this redundancy between
`README.rst` and `index.rst` - which I logged as follow up ticket in
#704.

(cherry picked from commit 2617449)
Fix broken docs sample DAG image, due to different syntax to render
images between Github and Sphinx.

(cherry picked from commit bc8a309)
…"method" (#702)

The issue is described in #696 which was discovered when a user was
creating a ProfileConfig with
`GoogleCloudServiceAccountDictProfileMapping(profile_args={"method":
"service-account"})` which was overriding the dbt profile method:

https://github.com/astronomer/astronomer-cosmos/blob/24aa38e528e299ef51ca6baf32f5a6185887d432/cosmos/profiles/bigquery/service_account_keyfile_dict.py#L21

when the profile args are mapped to the created profile below:

https://github.com/astronomer/astronomer-cosmos/blob/24aa38e528e299ef51ca6baf32f5a6185887d432/cosmos/profiles/bigquery/service_account_keyfile_dict.py#L42-L52

This is not an issue with the profile mapping example above and could
happen with any profile mapping by changing the "type" from
`dbt_profile_type` or "method" (if used) from `dbt_profile_method` in
the class.

The fix in this PR is to not allow args with "type" or "method" that are
different from the class variables in `profile_args`.

I think this is better than logging a warning because if either of those
fields are different the dbt run with the created profile will fail
anyways. This also allows backwards compatibility in the case users have
these already set in their profile args and it matches the class
variables.

Closes #696

(cherry picked from commit 8f7a04b)
Bug fixes

* Fix running models that use alias while supporting dbt versions by @binhnq94 in #662
* Make profiles_yml_path optional for ExecutionMode.DOCKER and KUBERNETES by @MrBones757 in #681
* Prevent overriding dbt profile fields with profile args of type or method by @jbandoro in #702
* Fix LoadMode.DBT_LS fail when dbt outputs WarnErrorOptions by @adammarples in #692
* Add support for env vars in RenderConfig for dbt ls parsing by @jbandoro in #690
* Add support for Kubernetes on_warning_callback by @david-mag in #673
* Fix ExecutionConfig.dbt_executable_path to use ``default_factory`` by @jbandoro in #678

Others

* Docs fix: example DAG in the README and docs/index by @tatiana in #705
* Docs improvement: highlight DAG examples in README by @iancmoritz and @jlaneve in #695
@tatiana tatiana requested a review from a team as a code owner November 23, 2023 14:41
@tatiana tatiana requested a review from a team November 23, 2023 14:41
@dosubot dosubot bot added size:XL This PR changes 500-999 lines, ignoring generated files. area:execution Related to the execution environment/mode, like Docker, Kubernetes, Local, VirtualEnv, etc dbt:run Primarily related to dbt run command or functionality execution:kubernetes Related to Kubernetes execution environment parsing:dbt_ls Issues, questions, or features related to dbt_ls parsing labels Nov 23, 2023
@tatiana tatiana added this to the 1.2.5 milestone Nov 23, 2023
@tatiana tatiana merged commit b8eeae8 into release-1.2 Nov 23, 2023
41 of 42 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
area:execution Related to the execution environment/mode, like Docker, Kubernetes, Local, VirtualEnv, etc dbt:run Primarily related to dbt run command or functionality execution:kubernetes Related to Kubernetes execution environment parsing:dbt_ls Issues, questions, or features related to dbt_ls parsing size:XL This PR changes 500-999 lines, ignoring generated files.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

7 participants