-
Notifications
You must be signed in to change notification settings - Fork 198
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
Support on_warning_callback
with TestBehavior.BUILD
and ExecutionMode.LOCAL
#1571
Conversation
remove args["on_warning_callback"] = on_warning_callback unused
✅ Deploy Preview for sunny-pastelito-5ecb04 canceled.
|
it seems that the CI is failing due to a different error (#1567) |
Codecov ReportAll modified and coverable lines are covered by tests ✅
Additional details and impacted files@@ Coverage Diff @@
## main #1571 +/- ##
=======================================
Coverage 97.34% 97.35%
=======================================
Files 80 80
Lines 4903 4920 +17
=======================================
+ Hits 4773 4790 +17
Misses 130 130 ☔ View full report in Codecov by Sentry. |
add DbtBuildLocalOperator test on_warning_callback
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@corsettigyg thanks a lot for improving this.
Ideally, we'd also have feature parity / fix this in the other executors, as an example:
- https://github.com/astronomer/astronomer-cosmos/blob/main/cosmos/operators/kubernetes.py#L120-L128 (which even has a generic class to handle warnings)
- https://github.com/astronomer/astronomer-cosmos/blob/main/cosmos/operators/docker.py#L96-L104
- https://github.com/astronomer/astronomer-cosmos/blob/main/cosmos/operators/gcp_cloud_run_job.py#L126-L134
- https://github.com/astronomer/astronomer-cosmos/blob/main/cosmos/operators/azure_container_instance.py#L104-L112
astronomer-cosmos/cosmos/operators/aws_ecs.py
Line 122 in 0811e46
class DbtBuildAwsEcsOperator(DbtBuildMixin, DbtAwsEcsBaseOperator):
So their build operators also can receive on_warning_callback
.
I understand these changes are outside the scope of the current PR, but could you please log a GitHub issue so we can keep track of them?
I'm happy for us to merge this PR once the checks pass.
on_warning_callback
with TestBehavior.BUILD
and ExecutionMode.LOCAL
Description
as of now, when we set TestBehavior.BUILD, we are not leveraging the method on_warning_callback that is available for Test nodes and Source Nodes. I have added the parsing to DbtBuildLocalOperator in order to fix it. I tested it locally and I got positive results
Related Issue(s)
#1569
Breaking Change?
Should not be
Checklist