Validating docstrings in Python files as RST
See original GitHub issueAs I understand it, rst-lint *.rst
works great on plain text files using reStructuredText.
I would like to be able to do rst-lint *.py
and have it pull out the Python docstrings, and check if they are valid reStructuredText.
Ideally any errors would retain the original line number from the Python file. That can probably be done via an offset if processing each docstring alone.
Issue Analytics
- State:
- Created 7 years ago
- Comments:7 (7 by maintainers)
Top Results From Across the Web
flake8-rst-docstrings - PyPI
This is an MIT licensed flake8 plugin for validating Python docstrings markup as reStructuredText (RST) using the Python library docutils.
Read more >Flake8 Plugin to Validate Python Docstrings As ... - Morioh
This is an MIT licensed flake8 plugin for validating Python docstrings markup as reStructuredText (RST) using the Python library docutils .
Read more >doctest — Test interactive Python examples — Python 3.11.1 ...
There are several common ways to use doctest: To check that a module's docstrings are up-to-date by verifying that all interactive examples still...
Read more >Documenting Python Code: A Complete Guide
Module docstrings are similar to class docstrings. Instead of classes and class methods being documented, it's now the module and any functions found...
Read more >Advanced Code Documentation Beyond Comments and ...
This article is for you if you are working on Python projects — whether it is writing a Python ... Google, Numpy, and...
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
I’ve made the first release of the new plugin
flake8-rst-docstrings
on PyPI, which usesrestructuredtext-lint
internally:https://pypi.python.org/pypi/flake8-rst-docstrings
(I’ll stop commenting on this issue now - thanks)
I’ve started working on this as a flake8 plugin under the name
flake8-rst-docstrings
,https://github.com/peterjc/flake8-rst-docstrings