{"id":6791,"library":"pydoclint","title":"PyDocLint","description":"PyDocLint is a fast Python docstring linter that verifies whether a function's docstring sections (arguments, returns, yields, and raises) accurately match its signature and implementation. It currently supports NumPy, Google, and Sphinx docstring styles, running significantly faster than older alternatives. The library is actively maintained with frequent releases, and its current version is 0.8.3.","status":"active","version":"0.8.3","language":"en","source_language":"en","source_url":"https://github.com/jsh9/pydoclint","tags":["linter","docstrings","code quality","flake8"],"install":[{"cmd":"pip install pydoclint","lang":"bash","label":"Install native CLI"},{"cmd":"pip install pydoclint[flake8]","lang":"bash","label":"Install as Flake8 plugin"}],"dependencies":[{"reason":"Requires Python 3.10 or newer.","package":"python","optional":false},{"reason":"Required if using pydoclint as a Flake8 plugin.","package":"flake8","optional":true}],"imports":[],"quickstart":{"code":"# my_module.py\ndef my_function(arg1: int, arg2: str) -> None:\n    \"\"\"\n    A sample function.\n\n    Parameters\n    ----------\n    arg1 : int\n        The first argument.\n    arg2 : str\n        The second argument.\n    \"\"\"\n    print(f'{arg1}, {arg2}')\n\n# pyproject.toml\n[tool.pydoclint]\nstyle = \"numpy\"\ncheck-arg-order = true\n\n# Terminal\n# Run pydoclint on a file or folder\npydoclint my_module.py\n# Or with a config file\npydoclint --config=pyproject.toml my_module.py\n# Or as a pre-commit hook (add to .pre-commit-config.yaml)\n# - repo: https://github.com/jsh9/pydoclint\n#   rev: <latest_tag> # e.g., 0.8.3\n#   hooks:\n#     - id: pydoclint\n#       args: [\"--config=pyproject.toml\"]","lang":"python","description":"To get started, install pydoclint and run it as a command-line tool on your Python files or directories. Configuration can be managed via a `pyproject.toml` file or command-line arguments."},"warnings":[{"fix":"Upgrade Python to 3.10 or higher, or pin pydoclint to a version older than 0.7.4.","message":"Python 3.9 support was dropped in version 0.7.4. Users on older Python versions will need to upgrade their Python environment to at least 3.10 to use pydoclint 0.7.4 and newer.","severity":"breaking","affected_versions":">=0.7.4"},{"fix":"Review `pyproject.toml` or other config files against the official documentation to ensure correct syntax and options.","message":"Configuration file validation was enhanced in version 0.7.4. Previously, malformed `pyproject.toml` or other config files might have been silently ignored or partially applied. Now, invalid configurations might lead to errors.","severity":"gotcha","affected_versions":">=0.7.4"},{"fix":"Upgrade pydoclint to the latest version (0.7.0 or newer) for comprehensive Google and Sphinx docstring style support.","message":"Earlier versions (prior to approximately 0.7.0) primarily supported NumPy-style docstrings, with Google and Sphinx style support added later. Users expecting full support for Google or Sphinx styles should ensure they are on a recent version.","severity":"gotcha","affected_versions":"<0.7.0"},{"fix":"Ensure type hints in docstrings precisely mirror those in function signatures. Adhere to standard Python naming conventions for methods and parameters.","message":"PyDocLint performs static analysis and expects exact matches for type hints between docstrings and function signatures. It does not recognize conventions like 'int, optional' for `Optional[int]`, requiring verbatim matching. Also, non-standard Pythonic naming (e.g., renaming `classmethod`) might lead to unexpected linting results.","severity":"gotcha","affected_versions":"all"}],"env_vars":null,"last_verified":"2026-04-15T00:00:00.000Z","next_check":"2026-07-14T00:00:00.000Z","problems":[]}