Open flying-sheep opened 5 years ago
Honestly, I’d just like napoleon to treat the returns section as free form, and only if there’s a rigorous definition list structure, napoleon should do its magic there.
Most functions return just a single value, and it should be possible to just write a description there and have it render as a plain paragraph.
Returns
=======
Foo bar baz
↓
… … Returns: Foo bar baz
Returns
=======
Foo
Bar baz
↓
… … Returns:
Foo
- Bar baz
Returns
=======
foo: Bar
baz
↓
… … Returns:
- foo :
Bar
- Baz
This would be great for us too!
I use
sphinx-autodoc-typehints
, but can’t seem to find a way to write aReturns
section in numpydoc style that doesn’t result in a:rtype:
being inserted.… results in “name” being treated as type
… results in “” being treated as type. Leaving out the “” just results in “name” being treated as type again.
… results in an empty description and “Desc” being used as return type.