-
Notifications
You must be signed in to change notification settings - Fork 14.7k
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
Remove cattrs
from airflow.lineage
#26134
Conversation
03f1940
to
75621e7
Compare
75621e7
to
6a15277
Compare
|
||
# prepare with manual inlets and outlets | ||
op1.pre_execute(ctx1) | ||
op1.post_execute(ctx1) |
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.
Thinking out loud, isn't it in-consistent that non-attr objects are not excluded to be set as "outlets" but excluded for inlets?
Example the following will evaluate to True
currently on L149:
assert op1.outlets == [a, file3]
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.
Yeah possibly - I didn't really change this behaviour so I didn't think about it
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.
@kaxil WDYT? Leave this "as it was" or fix it now?
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.
Would lean towards leave this "as it was" in this PR and fix it in a separate PR
6a15277
to
2a96489
Compare
Cattrs was used for two reasons: 1. As a hacky way of forcing templated fields on classes 2. As a way to store the outlets in XCom without needing pickle 1 has been fixed in core for a while now and classes can have "template_fields" properties (deeply) 2 is now done by using a combo of BaseSerialization and `attr.asdict`
0a3bcc9
to
55c9ee3
Compare
Cattrs was used for two reasons:
1 has been fixed in core for a while now and classes can have
"template_fields" properties (deeply)
2 is now done by using a combo of BaseSerialization and
attr.asdict
Part of #26130
Depends on #26142 (for making BaseSerialization.serialize public)