andrewgodwin commented on pull request #15142:
URL: https://github.com/apache/airflow/pull/15142#issuecomment-812144541


   > > `from airflow.models import Label`
   > 
   > How about hiding the `Label` class from the user entirely? Something like 
`task1 << "Label" << task2` and create the label automatically in 
`_set_relatives()`.
   
   I'd not be a huge fan of that design for two reasons:
   * If we ever want to add edge information beyond just a label (e.g. add a 
longer description), it means we have to go back to this pattern
   * It's relatively unobvious to new people reading the code what the meaning 
of a plain string is, whereas I think wrapping it in `Label` gives it immediate 
meaning to the casual reader


-- 
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.

For queries about this service, please contact Infrastructure at:
[email protected]


Reply via email to