Getting Started

Get up and running with depwhy in under a minute.

Installation

Install depwhy from PyPI using pip:

bash
pip install depwhy

If you use uv as your package manager, depwhy installs the same way:

bash
uv pip install depwhy

depwhy requires Python 3.10 or later.

Verify Installation

After installing, confirm that depwhy is available on your PATH:

bash
depwhy --version

You should see:

$ depwhy 0.1.1

Your First Analysis

Create a sample requirements.txt with a known conflict:

text
requests==2.28.0
urllib3==2.0.0

Then run depwhy against it:

bash
depwhy requirements.txt

depwhy resolves the full dependency graph and reports every conflict it finds, along with ranked fixes:

$ depwhy requirements.txt
2 conflict(s) found
urllib3
Problem: requests==2.28.0 requires urllib3>=1.21.1,<1.27, but you have urllib3==2.0.0 pinned
Solution: Remove your pin — use urllib3==1.26.18 (latest compatible)
→ pip install urllib3==1.26.18
Alternative: Upgrade requests to >=2.29.0 (loosens urllib3 upper bound)
→ pip install requests==2.29.0

Each conflict includes:

  • Problem — a plain-English description of which version constraints clash and why.
  • Solution — the lowest-risk fix, usually adjusting the pinned package.
  • Alternative — other viable fixes ranked by compatibility risk.

What's Next

  • CLI Reference — explore all available flags and output formats.
  • API Reference — use depwhy programmatically in your own Python code.