uranusjr commented on pull request #15285:
URL: https://github.com/apache/airflow/pull/15285#issuecomment-819424297


   > if you want to make this an enum, why can't you just keep the single State 
class and make it enum, or enum-like?
   
   I think that’d take away most of the reason of having an enum class. The 
main advantage of enums is to prevent invalid values from being passed (they’d 
result in a typing or runtime error). Combining all the possible state values 
into one enum means not all state values make sense for all contexts (some 
states are impossible on task instances, for example), and kind of defeats the 
purpose.


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