Open
Description
I am using sphinx2-autodoc2 to generate documentation for a Python class like this:
class Foo:
"""This is class foo"""
bar = 42
"""The bar of foo"""
When running this through Sphinx-autodoc2 it creates Foo.md
with the following relevant parts:
````{py:attribute} bar
:canonical: Foo.bar
:value: >
1
```{autodoc2-docstring} Foo.bar
```
````
Notice the ">" and extra linebreak!
What is wanted is more akin to:

This is caused by the following from myst_.py:
sphinx-autodoc2/src/autodoc2/render/myst_.py
Lines 348 to 362 in 13933a5
I'm not sure what the intent of the comment: # use > to ensure its understood as a string is supposed to mean.
The rst-renderer is not up to such shenigans:
sphinx-autodoc2/src/autodoc2/render/rst_.py
Lines 314 to 326 in 13933a5
I can make a PR with a proposed fix, are you still accepting those?
Metadata
Metadata
Assignees
Labels
No labels