Test if doctype types match signatures
Project description
pydoctest: docstring signature verification
File issues here: Issues tracker
Motivation
Pydoctest helps you verify that your docstrings match your function signatures. As a codebase evolves, you can some times forget to update the docstrings.
Installation
Install pydoctest with pip:
$ python3 -m pip install pydoctest
Usage
Navigate to your project location, and execute pydoctest
$ pydoctest
Output
Pydoctest supports outputting results either as JSON
or Text
with different verbosity options. By default, Text
is returned. To specify the output, invoke with --reporter
argument:
$ pydoctest --reporter [json | text]
For Text-output, --verbosity
can be provided with a value of 0 (quiet), 1 (show failed) or 2 (show all).
$ pydoctest --reporter text --verbosity 1
Configuration
Pydoctest can be configured with a config JSON file. By default, it will search for pydoctest.json
in the directory pydoctest is executed. A path can also be provided when executing:
$ pydoctest --config /path/to/pydoctest.json
Example pydoctest.json:
{
"include_paths": [ "server/*.py" ],
"fail_on_missing_docstring": true,
"parser": "google",
}
Docstring format can be specified with the --parser
argument:
$ pydoctest --parser google
Currently, only google is supported.
License
Pydoctest is licensed under the terms of the MIT License (see the LICENSE file).
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Hashes for pydoctest-0.1.5-py3-none-any.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 6c582bf334ddf79614f4a6a89397ff668e4d416891f8a1dd1acd162c458940c8 |
|
MD5 | d7affc6443596e3a82d7a1e837ab6e36 |
|
BLAKE2b-256 | dc082001700d9114df3c895c585859c36cff04ac71f40c6d17f09702f482e91d |