Skip to main content

Premium Python environment diagnostic CLI — your project's personal physician.

Project description

PyDoctor CLI (Command Line Interface)

PyDoctor is a standalone, developer-friendly diagnostic assistant for Python environments. It acts like a personal physician for your code — scanning your project and environment to prescribe fixes for misconfigurations, dependencies, and security vulnerabilities.

CI Status PyPI version Python versions License


🧭 Navigation


Project Description

PyDoctor isn't just a scanner; it's a complete remediation tool that performs static analysis on your project files and cross-references your environment against live security databases.

Key Features

  • Environment Analysis: Detects missing virtualenvs, outdated pip, or deprecated Python versions.
  • Dependency Fix: Automatically resolves conflicts and installs missing packages.
  • Security: Integrates with OSV.dev API to check against known CVEs/GHSAs.
  • Unused Detection: Identifies declared packages that are never imported.
  • Multi-Manager: Intelligent support for pip, Poetry, uv, and pdm.
  • Rich UI: Beautiful progress spinners, icons, and color-coded severities.

📦 Installation

PyDoctor requires Python 3.10+. For the best experience, we recommend using pipx.

# Recommended: Install globally in an isolated environment
pipx install pydoctor-cli

# Standard pip installation
pip install pydoctor-cli

⚡ Usage

Full Diagnosis

Run a comprehensive check-up on your project.

pydoctor diagnose

Automated Fixes

Let PyDoctor perform the heavy lifting. It will offer to install missing packages, upgrade outdated ones, and clean up your environment.

pydoctor fix

Release History

v2.0.0

  • 🚀 Major UI/UX Revamp: Introduced a premium "kernel/hacker" aesthetic with boxed reports, dynamic progress animations, and improved readability.
  • 🛡️ CI/CD Guard Mode: New pydoctor check --ci command to detect exposed secrets (AWS, GitHub, PyPI tokens) and insecure workflow patterns in GitHub Actions/GitLab CI.
  • 🐳 Docker Support: New pydoctor docker command to diagnose Python issues inside containers and audit Dockerfiles.
  • 🐙 GitHub Integration: New pydoctor github command for repository-wide health scans and local git configuration audits.
  • 📈 Advanced Health Scoring: Refined the 0-100 scoring algorithm with granular penalties for security vulnerabilities and CI/CD risks.
  • ⚡ Performance Boost: Parallel execution engine for scanning large codebases faster.
  • 🔍 Smart Environment Detection: Now automatically prompts users when no venv is found, preventing accidental system-wide changes.
  • 🎯 Context-Aware Reporting: Targeted commands (like pydoctor scan-unused or pydoctor github) now intelligently suppress unrelated scanner noise.
  • 🧠 OSV Deep-Fetching: Overcame upstream OSV API batch limits by implementing dynamic real-time fetching and caching of full vulnerability advisories natively.
  • 🔗 Transitive Dependency Tracking: PyDoctor now uniquely segregates mathematical/transitive dependencies from pure unused bloat, effectively preventing pydoctor fix from uninstalling required sub-packages.
  • 🛠️ Refined Git Discovery: Utilizes native git heuristics (--is-inside-work-tree & --show-toplevel) to flawlessly map out project roots and repository states, even when scanning from deeply nested sub-directories.
  • 🔮 Dynamic Fix Suggestions: The 🚀 Next Steps terminal guide now dynamically rules out the currently running command and gracefully self-hides when a project achieves a perfect 100/100 health rating.

v0.1.3

  • Enhanced Package Detection: Pydoctor now intelligently detects and uses your project's specific virtual environment (Poetry, UV, PDM, or standard venv) to run all scans and diagnoses.
  • Improved Architecture: Refactored core modules to reduce complexity and improve maintainability (resolved C901 linting errors).
  • Fix Rendering Errors: Resolved issues with undefined verbose detail renderers in the CLI.

v0.1.2

  • Maintenance: Minor internal fixes and linting improvements for CI/CD stability.
  • Professional Meta: Revamped pyproject.toml with complete author metadata and SEO keywords.

v0.1.1

  • Bug Fixes: Minor improvements to dependency scanning reliability.
  • Metadata Update: Initial professional README branding.

v0.1.0

  • Initial Release: Core diagnostic engine with support for Environment, Dependencies, Outdated Packages, Security, and Unused Package scans.
  • Remediation: Initial support for auto-fixing issues via pydoctor fix.

Verified Details


👥 Maintainers

📄 Meta

  • License: Apache License 2.0
  • Author: Favour Bamgboye
  • Requires: Python >=3.10
  • Classifiers:
    • Development Status :: 4 - Beta
    • Intended Audience :: Developers
    • License :: OSI Approved :: Apache Software License
    • Operating System :: OS Independent
    • Programming Language :: Python :: 3
    • Programming Language :: Python :: 3.10
    • Programming Language :: Python :: 3.11
    • Programming Language :: Python :: 3.12
    • Topic :: Software Development :: Quality Assurance

Developed with ❤️ by Favour Bamgboye

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

pydoctor_cli-2.0.0.tar.gz (59.8 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

pydoctor_cli-2.0.0-py3-none-any.whl (69.9 kB view details)

Uploaded Python 3

File details

Details for the file pydoctor_cli-2.0.0.tar.gz.

File metadata

  • Download URL: pydoctor_cli-2.0.0.tar.gz
  • Upload date:
  • Size: 59.8 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.1.0 CPython/3.13.7

File hashes

Hashes for pydoctor_cli-2.0.0.tar.gz
Algorithm Hash digest
SHA256 8f58bab41bddddd49a28383f073b75cd17884a593a194609dd8a0b72dee03b5e
MD5 afa490b8423844600c707594f72651a3
BLAKE2b-256 845787edc1b8cb947f269bb82d79b9ecb35fde6dd2c450c8282d81c9b4d53700

See more details on using hashes here.

Provenance

The following attestation bundles were made for pydoctor_cli-2.0.0.tar.gz:

Publisher: publish.yml on iamAgbaCoder/pydoctor-cli

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file pydoctor_cli-2.0.0-py3-none-any.whl.

File metadata

  • Download URL: pydoctor_cli-2.0.0-py3-none-any.whl
  • Upload date:
  • Size: 69.9 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.1.0 CPython/3.13.7

File hashes

Hashes for pydoctor_cli-2.0.0-py3-none-any.whl
Algorithm Hash digest
SHA256 cb991a2a86a0ac72b171c3c6a950eac2290f8eb2fa5f2542bd43e2b9be048241
MD5 769b6d6fa0e6e0486a38c8ba41460796
BLAKE2b-256 e346ad3e69aad557b1f662b7db1d4e7daaa69692e5e5657fba544cb40c855cd9

See more details on using hashes here.

Provenance

The following attestation bundles were made for pydoctor_cli-2.0.0-py3-none-any.whl:

Publisher: publish.yml on iamAgbaCoder/pydoctor-cli

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page