Icon for Pipenv: Python Dev Workflow for Humans

Pipenv: Python Dev Workflow for Humans

Pipenv brings together pip and virtualenv into a single tool that manages your project's dependencies the way you actually think about them. No more juggling requirements.txt files and manually activating virtual environments.

$ uv add pipenv

What It Looks Like

# Start a new project.
$ pipenv install requests

# Pipenv creates a virtual environment, installs the package,
# and generates both Pipfile and Pipfile.lock automatically.

# Add a dev dependency.
$ pipenv install pytest --dev

# Activate the environment.
$ pipenv shell

# Run a command inside the environment.
$ pipenv run python app.py

# Install from an existing Pipfile.
$ pipenv install

# See your dependency graph.
$ pipenv graph

# Check for known security vulnerabilities.
$ pipenv check

Every command does what you'd guess it does. No memorizing activation scripts. No wondering which requirements.txt is current.

The Pipfile

[[source]]
url = "https://pypi.org/simple"
verify_ssl = true

[packages]
requests = "*"
flask = ">=2.0"

[dev-packages]
pytest = "*"
black = "*"

[requires]
python_version = "3.11"

Human-readable. Version-controlled. The Pipfile.lock beside it captures exact versions with hashes for deterministic, verified builds. You edit the Pipfile. Pipenv manages the lockfile.

The Problem It Solved

Before Pipenv, the Python dependency workflow looked like this: create a virtualenv manually, activate it (differently on every OS), pip install things, remember to pip freeze > requirements.txt, hope your colleagues have the same versions, discover they don't, debug for an hour. The tools worked. The workflow was hostile.

Pipenv replaced all of that with a single command-line tool. Pipfile replaced requirements.txt with something readable. Pipfile.lock gave Python deterministic builds, the way npm and Ruby's Bundler had for years. Hash verification meant you could trust your dependencies hadn't been tampered with.

The Python Packaging Authority adopted it as a recommended tool. It wasn't a technical breakthrough. It was a workflow breakthrough. The same philosophy behind Requests: if developers keep making the same mistakes, the tool is wrong, not the developers.

The Legacy

Today, uv from Astral is Pipenv's spiritual successor. It solves the same problems faster, with a broader scope, and it's built by a team rather than a single maintainer. That's a good thing. The ideas Pipenv introduced — unified dependency management, lockfiles for Python, developer experience as a first-class concern — live on in better implementations.

That's exactly how open source should work. You plant a flag that says "this experience is unacceptable." Others build something better. The ecosystem improves. The flag stays planted.

Install

$ uv add pipenv

Resources