BasPH commented on a change in pull request #6317: [AIRFLOW-5644] Simplify 
TriggerDagRunOperator usage
URL: https://github.com/apache/airflow/pull/6317#discussion_r336735481
 
 

 ##########
 File path: airflow/operators/dagrun_operator.py
 ##########
 @@ -75,24 +63,21 @@ def __init__(
             self.execution_date = None
         else:
             raise TypeError(
-                'Expected str or datetime.datetime type '
-                'for execution_date. Got {}'.format(
-                    type(execution_date)))
+                "Expected str or datetime.datetime type for execution_date. "
+                "Got {}".format(type(execution_date))
+            )
 
     def execute(self, context):
 
 Review comment:
   The `__init__` arguments are already type annotated. Personally not a fan of 
these `if/else` type checks everywhere, it's against Python's nature :-)  Do 
you think we should remove 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.
 
For queries about this service, please contact Infrastructure at:
[email protected]


With regards,
Apache Git Services

Reply via email to