pyinvoke / invocations

Reusable Invoke tasks
http://invocations.readthedocs.io
BSD 2-Clause "Simplified" License
163 stars 28 forks source link

The sphinx plugin doesn't seem to work with sphinx-autodoc-typehints and sphinx-autodoc-defaultargs #33

Open red8888 opened 1 year ago

red8888 commented 1 year ago

I use these extensions:

They work for regular public functions, but anything annotated with @task doesn't pull in the type hint and default value from the function definition.

Is it possible to configure the invoke ext to work with this somehow?

I should add I'm using this guys code snippet to patch in support for type hints in the first place: https://github.com/pyinvoke/invoke/issues/357#issuecomment-583851322

kasium commented 8 months ago

@red8888 I had a similar issue and created https://github.com/SAP/invoke-plugin-for-sphinx for this. Disclaimer: I'm the author of it