tessl install tessl/pypi-pep257@0.7.0Python docstring style checker for PEP 257 compliance
Agent Success
Agent success rate when using this tile
72%
Improvement
Agent success rate improvement when using this tile compared to baseline
1.04x
Baseline
Agent success rate without this tile
69%
Build a focused docstring style checker that enforces whitespace, formatting, quote usage, and punctuation rules for Python docstrings. The checker should rely on the dependency to evaluate only the D2xx–D4xx rule family and present results through a callable API and a CLI entry point.
# noqa: D4xx comments suppress the corresponding violation when honor_noqa=True. @testhonor_noqa=False, so the same violation is emitted. @testinclude_source=True, each violation output includes the offending docstring lines beneath the message. @testinclude_count=True, the scan appends the total number of whitespace/formatting/quote/punctuation violations after the detailed messages. @test@generates
from typing import Sequence
def run_docstring_style_scan(
paths: Sequence[str],
*,
convention: str | None = None,
honor_noqa: bool = True,
include_source: bool = False,
include_explanations: bool = True,
include_count: bool = False,
) -> list[str]:
"""Return formatted violation messages for whitespace/formatting/quote/punctuation docstring rules (D2xx–D4xx) only."""
def main(argv: Sequence[str] | None = None) -> int:
"""CLI entry that accepts paths plus flags (--convention, --no-noqa, --source, --no-explain, --count) and exits 0 when clean, 1 when violations are found, and 2 on invalid options."""Docstring style checker providing whitespace, formatting, quote, and punctuation validation for the D2xx–D4xx rule family.