gdavoian commented on PR #29821:
URL: https://github.com/apache/airflow/pull/29821#issuecomment-1802186567

   @potiuk do you have any ideas on how it would fit into `BaseOperator`? 
Because I can only think about something like `templateable_fields` (the exact 
naming isn't important at the moment) to exclude them from the check. But 
simultaneously having two entities like `template_fields` and 
`templateable_fields` would be very misleading: the former is a list of fields 
that **can be** templated and the latter is a list of fields that **are allowed 
to be** templated, meaning that some fields (e.g., `BaseOperator.email`) have 
to be added to both lists at the same time... Again, the exact naming doesn't 
matter here as soon as the whole idea is weird.
   
   And that actually leads to my initial question: why did we ever need that 
check in the first place? `BaseOperator` doesn't define any `template_fields` 
by default, leaving that up to developers of third-party/custom operators to do 
that, which is completely fine. Thus, it's the responsibility of those 
developers to ensure their operators are valid and serializable, isn't it?


-- 
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: commits-unsubscr...@airflow.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org

Reply via email to