>I am a little confused as to how I can process the output generated by autodoc in my own extension, though.
>It would be impractical for me to re-develop everything already present in autodoc, due to time constraints. Is it possible to create a fork of autodoc and add the feature?
You don't need to fork autodoc extension because autodoc put a
docstring of the python object as is.
For example, a function having docstring will be converted to the
following output internally:
Source code:
```
def some_func(foo, bar, baz):
"""Some wonderful feature.
Some good explanation of some_func().
The mark-ups inside the docstring will be **kept** as is.
.. image:: /path/to/image.png
"""
```
Output:
```
.. py:function:: some_func(foo, bar, baz)
Some wonderful feature.
Some good explanation of some_func().
The mark-ups inside the docstring will be **kept** as is.
.. image:: /path/to/image.png
```
After the conversion, Sphinx starts to process the generated reST
document as same as from the file.
As I commented above, autodoc does not modify docstrings at all.
To realize your idea, what you just do is to create a directive named
"rest_parameters" that generates a field list from its input.
Input:
```
.. rest_parameters:: parameters.yaml
- node: r_allocation_node
- resource_class: r_resource_class
- state: r_allocation_state
- owner: owner
- fields: fields
- limit: limit
- marker: marker
- sort_dir: sort_dir
- sort_key: sort_key
```
Output:
```
:node: explanation for r_allocation_node
:resource_class: explanation for r_resource_class
...
```
>Can we set up a meeting with the team to discuss this?
Can you speak Japanese? It's okay if you can :-)
If not, it's difficult to discuss with your team because I can't speak
English at all.
(I'm also not familiar with writing English text too...)
Thanks,
Takeshi KOMIYA
2022年1月10日(月) 18:08 'Mahnoor Asghar' via sphinx-dev
> To view this discussion on the web, visit
https://groups.google.com/d/msgid/sphinx-dev/CAMJtAz8mSav_zNq6Ki%2Brhm2hEAbbL6Fm3SdHxzSR1DvAqDDSzQ%40mail.gmail.com.