Skip to main content

doc-cov

doc-cov is a tool for measuring docstring coverage of Python project.

  • Python versions >= 3.6

Quick start

  1. Install doc-cov from pip.
  2. Use doccov PROJECT_PATH
$ doccov tests/sample_project
function     3 /   5 60.00%

Options

Target object

doc-cov can measure docstring coverage of functions, classes and modules.

functions (default, -f)

$ doccov tests/sample_project -f
function     3 /   5 60.00%

classes -c

$ doccov tests/sample_project -c
class        2 /   2 100.00%

modules -m

$ doccov tests/sample_project -m
module       3 /   7 42.86%

Output

str (default, --output str)

$ doccov tests/sample_project -fmc --output str
class        2 /   2 100.00%
module       3 /   7 42.86%
function     3 /   5 60.00%

csv --output csv

$ doccov tests/sample_project -fmc --output csv
coverage,class,2,2,100.00%
coverage,module,3,7,42.86%
coverage,function,3,5,60.00%

Target

Print coverage of whole (default)

$ doccov tests/sample_project
function     3 /   5 60.00%

Print all coverage of modules --all

$ doccov tests/sample_project --all
=============================
module_fulldoc
-----------------------------
function     1 /   1 100.00%
=============================
package_A
-----------------------------
function     0 /   0 -
=============================
package_A.module_fulldoc
-----------------------------
function     1 /   1 100.00%
=============================
package_B
-----------------------------
function     0 /   0 -
=============================
package_B.module_shortdoc
-----------------------------
function     1 /   1 100.00%
=============================
package_B.package_B_1
-----------------------------
function     0 /   0 -
=============================
package_B.package_B_1.module_nodoc
-----------------------------
function     0 /   2 0.00%
=============================
coverage
-----------------------------
function     3 /   5 60.00%

Report to pull request

Add comment to github pull request.

$ doccov <project> -fmc --output csv > doccov.csv
$ GITHUB_TOKEN=XXXXX doccov-report doccov.csv

CircleCi
Add pull request comment using circle-ci environment.

Other
Required following environment

  • PROJECT_USERNAME
  • PROJECT_REPONAME
  • PR_NUMBER

Metadata

Release files for doc-cov 0.4.0

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for doc-cov 0.4.0
File Size Uploaded Provenance Actions
doc-cov-0.4.0.tar.gz 5.6 kB Without provenance Details for doc-cov-0.4.0.tar.gz

Built distribution (wheel)

Table of built distributions (wheels) for doc-cov 0.4.0
File Interpreter ABI Platform Actions
doc_cov-0.4.0-py3-none-any.whl Python 3 none any Details for doc_cov-0.4.0-py3-none-any.whl

Total release size: 12.7 kB

Release files / doc-cov-0.4.0.tar.gz

Download URL doc-cov-0.4.0.tar.gz
Size 5.6 kB
Tags Source
SHA-256 checksum
How to use checksums
28990976f00f9855c56c35473e9b1e0d1d79e51254d62b5eb311a10dacae9950
BLAKE2b-256 checksum
How to use checksums
b5953488ac6d1174a40a1ca20559ada6eb540ebe39491a3a931484f166d0a835
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/1.13.0 pkginfo/1.5.0.1 requests/2.18.4 setuptools/40.8.0 requests-toolbelt/0.9.1 tqdm/4.31.1 CPython/3.6.6

Release files / doc_cov-0.4.0-py3-none-any.whl

Download URL doc_cov-0.4.0-py3-none-any.whl
Size 7.1 kB
Tags Python 3
SHA-256 checksum
How to use checksums
18bf921e09579f1f22f2b78c9b725c198a5baaad07ab0a88cddbeb0ea4815167
BLAKE2b-256 checksum
How to use checksums
232fd0a330f9fee31f829a31a0809b127acefa81f6523fdf7d4e826692e475c2
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/1.13.0 pkginfo/1.5.0.1 requests/2.18.4 setuptools/40.8.0 requests-toolbelt/0.9.1 tqdm/4.31.1 CPython/3.6.6

Security for doc-cov 0.4.0

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

No provenance found

None of the files in this release were uploaded with provenance metadata.

A note on package security

PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.

To learn more about protecting yourself from malicious actors, visit our package security documentation.

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page