You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@airflow.apache.org by GitBox <gi...@apache.org> on 2022/06/28 03:18:44 UTC

[GitHub] [airflow] dstandish commented on a diff in pull request #24667: Clean up task decorator type hints and docstrings

dstandish commented on code in PR #24667:
URL: https://github.com/apache/airflow/pull/24667#discussion_r907990734


##########
airflow/decorators/__init__.pyi:
##########
@@ -124,20 +124,14 @@ class TaskDecoratorCollection:
     @overload
     def virtualenv(self, python_callable: Function) -> Task[Function]: ...
     @overload
-    def branch(
-        self, python_callable: Optional[Callable] = None, multiple_outputs: Optional[bool] = None, **kwargs
-    ) -> TaskDecorator:
-        """Wraps a python function into a BranchPythonOperator
+    def branch(self, *, multiple_outputs: Optional[bool] = None, **kwargs) -> TaskDecorator:

Review Comment:
   looks like you dropped an arg `python_callable`
   
   also, seems the underlying method isn't kwargs only?  but maybe we just want to not encourage use of args



-- 
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-unsubscribe@airflow.apache.org

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