gituser/production/: docstring-parser-0.12 metadata and description
"Parse Python docstrings in reST, Google and Numpydoc format"
| author | Marcin Kurczewski |
| author_email | rr-@sakuya.pl |
| classifiers |
|
| description_content_type | text/markdown |
| license | MIT |
| provides_extras | test |
| requires_dist |
|
| requires_python | >=3.6 |
| File | Tox results | History |
|---|---|---|
docstring_parser-0.12-py3-none-any.whl
|
|
docstring_parser
Parse Python docstrings. Currently support ReST, Google, Numpydoc-style and Epydoc docstrings.
Example usage:
>>> from docstring_parser import parse
>>>
>>>
>>> docstring = parse(
... '''
... Short description
...
... Long description spanning multiple lines
... - First line
... - Second line
... - Third line
...
... :param name: description 1
... :param int priority: description 2
... :param str sender: description 3
... :raises ValueError: if name is invalid
... ''')
>>>
>>> docstring.long_description
'Long description spanning multiple lines\n- First line\n- Second line\n- Third line'
>>> docstring.params[1].arg_name
'priority'
>>> docstring.raises[0].type_name
'ValueError'
Contributing
This project uses precommit. You can install it with
python3 -m pip install --user pre-commit and running pre-commit install.