-
Notifications
You must be signed in to change notification settings - Fork 193
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
Remediated default
behavior, added documentation
#378
Conversation
… default values
Codecov ReportAll modified and coverable lines are covered by tests ✅
Additional details and impacted files@@ Coverage Diff @@
## main #378 +/- ##
=======================================
Coverage 94.04% 94.04%
=======================================
Files 11 11
Lines 890 890
=======================================
Hits 837 837
Misses 53 53 ☔ View full report in Codecov by Sentry. 🚀 New features to boost your workflow:
|
cc: @pankajastro - ready for review! |
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.
Hi @jroach-astronomer , thanks for these contributions!
My understanding is that there are two types of changes in this PR:
- Linting improvements
- Fix/change of behaviour of default config in the YAML file
How did you come up with these linting changes? Was it using the project's pre-commit
? It would be great if we separated these from the (2)
@tatiana, that's right, these changes were made using |
@pankajastro , I've resolved our conversations and made the changes you've requested. |
Hi @jroach-astronomer, Look like there are some conflicts. Could you please resolve them? |
Merge conflict resolved! |
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.
thanks for improving it.
#295 outlined a documentation change that would better outline the workflow for defining and using a "default" block when creating DAGs with DAG Factory. In its most basic use, a
default
block at the top of a YAML file would be used, followed by the DAG-definitions leveraging these default values.During the documentation and testing process, it was discovered that the previously-expected behavior was not being implemented. This was due to this code (https://github.com/astronomer/dag-factory/blob/main/dagfactory/dagfactory.py#L136C1-L140C18), which completely overrode
default_config
, rather than just thedefault_args
key-value pair.To handle this, both a change to the logic above as well the appropriate unit-tests were written. This change allowed for the behavior in #295 to be completely implemented and documented.