Greg Gydush
01/18/2023, 11:15 PMYee
Greg Gydush
01/19/2023, 1:11 AM@task
decorator.
from flytekit import task
@task
def test_task(x: int) -> int:
"""My test task.
Args:
x: Integer for test
"""
return x
Autodoc picks up the file, but does not document test_task
- still trying to figure out why, but I think it has something to do with the decorator converting the object to a PythonFunctionTask
instancetest_task
function is properly documented with sphinx-autodoc__doc__
property 🤔Yee
Greg Gydush
01/19/2023, 1:19 AMYee
Greg Gydush
01/19/2023, 1:32 AM.. automodule:: flyte_common.my_task
:members:
:undoc-members:
:show-inheritance:
.. autoclass:: flyte_common.my_task.my_task
:members:
^ Seems like using automodule is not working, but autoclass directly on the task is working..Yee
Greg Gydush
01/19/2023, 1:42 AM[app] emitting event: 'autodoc-skip-member'('module', 'example_task', <flytekit.core.python_function_task.PythonFunctionTask object at 0x7fb9c4
[app] emitting event: 'autodoc-skip-member'('module', 'example_workflow', WorkflowBase - flyte_common.my_task.example_workflow && Inputs (1): {