SandyChapman commented on a change in pull request #16517:
URL: https://github.com/apache/beam/pull/16517#discussion_r800809637
##########
File path: sdks/python/apache_beam/transforms/ptransform.py
##########
@@ -1003,6 +1003,8 @@ def default_label(self):
def ptransform_fn(fn):
+ # type: (Callable) -> (...) -> _PTransformFnPTransform
Review comment:
That's right. Because this is a decorator, the function's type is that
which takes a function and returns another function.
I.e. ptransform_fn's `fn` argument is a Callable, and the result of calling
`ptransform_fn` is another callable that returns a `_PTransformFnPTransform`.
```
type: (Callable) -> (...) -> _PTransformFnPTransform
^^^^^^^^^^ ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
param fn return type
```
--
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: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]