uranusjr commented on code in PR #29355:
URL: https://github.com/apache/airflow/pull/29355#discussion_r1096633749
##########
airflow/models/taskinstance.py:
##########
@@ -448,21 +448,30 @@ class TaskInstance(Base, LoggingMixin):
note = association_proxy("task_instance_note", "content",
creator=_creator_note)
task: Operator # Not always set...
- def __init__(
- self,
+ @staticmethod
+ def from_task(
Review Comment:
I like this, but this may not be viable. Creating a TaskInstance out-of-band
has historically been used quite pervasively by users, and this could
potentially break many installations. We could still do this (especially since
we are trying to talk people off calling various Airflow internals anyway), but
need to be aware of the possible implications.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]