Python pipx

pipx installs Python CLI applications, each in its own isolated venv.

Installed applications come from pipx list --json; only each venv’s main package is tracked, never the packages injected beside it. There is no search operation: the request was closed as not planned, since PyPI exposes no search API and custom search is out of pipx’s scope (see pipx issue 777).

Note

The outdated query prefers pipx 1.16.0’s native pipx list --outdated, which checks every venv in one call, each against its own backend (pip or uv). An older pipx falls back to probing each venv with its embedded pip, one call per application. The version floor stays at 1.0.0 so an older pipx remains fully usable: only the outdated path degrades.

Note

The supply-chain cooldown rides on the underlying pip and needs that pip to be at least 26.1, the first release to honor --uploaded-prior-to; older pip silently ignores the release-age gate.

Platforms

  • 🅱️ BSD

  • 🐧 Linux

  • 🍎 macOS

  • ⨂ Unix

  • 🪟 Windows

Operations

Operation

Supported

installed

outdated

search

install

upgrade

upgrade_all

remove

sync

cleanup

Ecosystem

  • Accepted purl types: pkg:pipx, pkg:pypi

Usage

$ mpm --pipx installed
$ mpm --pipx upgrade --all
$ mpm install pkg:pipx/hello
$ mpm --dry-run --pipx upgrade --all

Every example above accepts --dry-run, which simulates the underlying manager calls without touching the system: the safe way to watch what mpm would do before trusting it.

Deselect the manager for a single run with --no-pipx, disable it from your configuration, or tune its invocation attributes with per-manager overrides.

Command line

  • CLI names, in lookup order: pipx

The version is extracted from the output of pipx --version with:

r"(?P<version>\S+)"

Privilege escalation

mpm runs this manager as the current user and never prepends sudo by default. Flip the policy for its privileged operations with --sudo or the per-manager sudo override.

See privilege escalation for the full policy.

Cooldown

mpm natively enforces its release-age cooldown on Python pipx, injecting the PIP_UPLOADED_PRIOR_TO environment variable on every call.

  • Status: ✅ Enforced (via pip’s env var; needs the underlying pip ≥ 26.1)

  • Mechanism: inherits PIP_UPLOADED_PRIOR_TO

  • Reference: pypa/pipx#1811

Reference traces

Raw native outputs captured in the manager source: the reference mpm’s parsers were written against. If you know Python pipx well and a transcript below looks wrong, or a newer release changed its output format, report it.

$ pipx list --json
{
  "pipx_spec_version": "0.1",
  "venvs": {
      "pycowsay": {
        "metadata": {
          "injected_packages": {},
          "main_package": {
            "app_paths": [
              {
                "__Path__": "~/.local/pipx/venvs/pycowsay/bin/pycowsay",
                "__type__": "Path"
              }
            ],
            "app_paths_of_dependencies": {},
            "apps": [
              "pycowsay"
            ],
            "apps_of_dependencies": [],
            "include_apps": true,
            "include_dependencies": false,
            "package": "pycowsay",
            "package_or_url": "pycowsay",
            "package_version": "0.0.0.1",
            "pip_args": [],
            "suffix": ""
          },
        "pipx_metadata_version": "0.2",
        "python_version": "Python 3.10.4",
        "venv_args": []
      }
    }
  }
}
$ pipx list --outdated --output=json
{
  "command": ["list"],
  "data": {
    "packages_checked": 1,
    "packages": [
      {
        "environment": "pycowsay",
        "package": "pycowsay",
        "version": "0.0.0.1",
        "latest_version": "0.0.0.2",
        "injected": false,
        "pinned": false
      }
    ],
    "skipped": []
  },
  "errors": [],
  "exit_code": 0,
  "pipx_result_version": "1",
  "status": "success"
}
$ pipx runpip pycowsay list --no-color --format=json --outdated             > --verbose --quiet
[
  {
    "name": "pycowsay",
    "version": "0.0.0.1",
    "location": "~/.local/pipx/venvs/pycowsay/lib/python3.10/site-packages",
    "installer": "pip",
    "latest_version": "0.0.0.2",
    "latest_filetype": "wheel"
  }
]