# System map — pypa/virtualenv

> Canonical page: https://codevetter.com/unpack/virtualenv/system-map

# System map — pypa/virtualenv

Scanned commit 571bc2041dae5ecbd250d82ec7ef482cfd3c3b69 (2026-10-02). Generated by codevetter codevetter 1.15.0 on 2026-10-02.

Source inspection; upstream code and tests were not executed.

The runtime is a Python CLI and library organized around a creation session. Discovery, creation, seeding, and activation are selected through installed package metadata. Persistent state lives in app-data folders, while generated environment files live under the chosen destination with a guarded adjacent redirect. Packaging supports wheels, source distributions, and a standalone zipapp.
- The console script targets virtualenv.__main__:run_with_catch; python -m virtualenv reaches the same wrapper, while the package exports cli_run and session_via_cli. — [pyproject.toml#L69-L77](https://github.com/pypa/virtualenv/blob/571bc2041dae5ecbd250d82ec7ef482cfd3c3b69/pyproject.toml#L69-L77) [src/virtualenv/__main__.py#L71-L95](https://github.com/pypa/virtualenv/blob/571bc2041dae5ecbd250d82ec7ef482cfd3c3b69/src/virtualenv/__main__.py#L71-L95) [src/virtualenv/__init__.py#L1-L10](https://github.com/pypa/virtualenv/blob/571bc2041dae5ecbd250d82ec7ef482cfd3c3b69/src/virtualenv/__init__.py#L1-L10)
- build_parser discovers the interpreter before constructing CreatorSelector, SeederSelector, and ActivationSelector; Session.run executes create → seed → activate → final configuration write. — [src/virtualenv/run/__init__.py#L100-L118](https://github.com/pypa/virtualenv/blob/571bc2041dae5ecbd250d82ec7ef482cfd3c3b69/src/virtualenv/run/__init__.py#L100-L118) [src/virtualenv/run/session.py#L70-L92](https://github.com/pypa/virtualenv/blob/571bc2041dae5ecbd250d82ec7ef482cfd3c3b69/src/virtualenv/run/session.py#L70-L92)
- Builtin discovery delegates get_interpreter to python-discovery; local PythonInfo is a compatibility re-export, and python-discovery>=1.6 is a runtime dependency. — [src/virtualenv/discovery/builtin.py#L8-L28](https://github.com/pypa/virtualenv/blob/571bc2041dae5ecbd250d82ec7ef482cfd3c3b69/src/virtualenv/discovery/builtin.py#L8-L28) [src/virtualenv/discovery/py_info.py#L1-L9](https://github.com/pypa/virtualenv/blob/571bc2041dae5ecbd250d82ec7ef482cfd3c3b69/src/virtualenv/discovery/py_info.py#L1-L9) [pyproject.toml#L52-L60](https://github.com/pypa/virtualenv/blob/571bc2041dae5ecbd250d82ec7ef482cfd3c3b69/pyproject.toml#L52-L60)
- Creator entry points include CPython, PyPy, GraalPy, RustPython, and stdlib venv implementations; CreatorSelector filters them through can_create and aliases the first compatible VirtualenvBuiltin as builtin. — [pyproject.toml#L78-L100](https://github.com/pypa/virtualenv/blob/571bc2041dae5ecbd250d82ec7ef482cfd3c3b69/pyproject.toml#L78-L100) [src/virtualenv/run/plugin/creators.py#L33-L64](https://github.com/pypa/virtualenv/blob/571bc2041dae5ecbd250d82ec7ef482cfd3c3b69/src/virtualenv/run/plugin/creators.py#L33-L64)
- AppDataDiskFolder separates interpreter JSON, downloaded wheel house, versioned installation images, update logs, and extracted zipapp resources; make_app_data chooses disk, read-only, or temporary storage. — [src/virtualenv/app_data/via_disk_folder.py#L78-L114](https://github.com/pypa/virtualenv/blob/571bc2041dae5ecbd250d82ec7ef482cfd3c3b69/src/virtualenv/app_data/via_disk_folder.py#L78-L114) [src/virtualenv/app_data/__init__.py#L49-L72](https://github.com/pypa/virtualenv/blob/571bc2041dae5ecbd250d82ec7ef482cfd3c3b69/src/virtualenv/app_data/__init__.py#L49-L72)
- Seeding integrates distlib script generation, pip download subprocesses, and PyPI JSON metadata; FromAppData installs images directly, whereas PipInvoke runs pip under the created interpreter. — [src/virtualenv/seed/embed/via_app_data/pip_install/base.py#L169-L177](https://github.com/pypa/virtualenv/blob/571bc2041dae5ecbd250d82ec7ef482cfd3c3b69/src/virtualenv/seed/embed/via_app_data/pip_install/base.py#L169-L177) [src/virtualenv/seed/wheels/acquire.py#L138-L173](https://github.com/pypa/virtualenv/blob/571bc2041dae5ecbd250d82ec7ef482cfd3c3b69/src/virtualenv/seed/wheels/acquire.py#L138-L173) [src/virtualenv/seed/embed/pip_invoke.py#L26-L41](https://github.com/pypa/virtualenv/blob/571bc2041dae5ecbd250d82ec7ef482cfd3c3b69/src/virtualenv/seed/embed/pip_invoke.py#L26-L41) [src/virtualenv/seed/wheels/periodic_update.py#L448-L465](https://github.com/pypa/virtualenv/blob/571bc2041dae5ecbd250d82ec7ef482cfd3c3b69/src/virtualenv/seed/wheels/periodic_update.py#L448-L465)
- Hatchling and hatch-vcs build the package and generate version.py; the custom SbomBuildHook conditionally embeds a CycloneDX SBOM, and tox defines interpreter tests, documentation, typing, package checks, and zipapp builds. — [pyproject.toml#L1-L7](https://github.com/pypa/virtualenv/blob/571bc2041dae5ecbd250d82ec7ef482cfd3c3b69/pyproject.toml#L1-L7) [pyproject.toml#L201-L213](https://github.com/pypa/virtualenv/blob/571bc2041dae5ecbd250d82ec7ef482cfd3c3b69/pyproject.toml#L201-L213) [hatch_build.py#L223-L253](https://github.com/pypa/virtualenv/blob/571bc2041dae5ecbd250d82ec7ef482cfd3c3b69/hatch_build.py#L223-L253) [tox.toml#L2-L29](https://github.com/pypa/virtualenv/blob/571bc2041dae5ecbd250d82ec7ef482cfd3c3b69/tox.toml#L2-L29)
- make_zipapp bundles hashed, locked pure-Python wheels and a custom import loader; release CI publishes distributions to PyPI and zipapp/SBOM assets to GitHub, then updates get-virtualenv. — [tasks/make_zipapp.py#L63-L103](https://github.com/pypa/virtualenv/blob/571bc2041dae5ecbd250d82ec7ef482cfd3c3b69/tasks/make_zipapp.py#L63-L103) [tasks/make_zipapp.py#L127-L140](https://github.com/pypa/virtualenv/blob/571bc2041dae5ecbd250d82ec7ef482cfd3c3b69/tasks/make_zipapp.py#L127-L140) [tasks/__main__zipapp.py#L178-L188](https://github.com/pypa/virtualenv/blob/571bc2041dae5ecbd250d82ec7ef482cfd3c3b69/tasks/__main__zipapp.py#L178-L188) [.github/workflows/release.yaml#L126-L174](https://github.com/pypa/virtualenv/blob/571bc2041dae5ecbd250d82ec7ef482cfd3c3b69/.github/workflows/release.yaml#L126-L174)

Every claim links to its cited files at the pinned commit. Citations identify source evidence; they do not establish runtime correctness. Independent CodeVetter scan — not reviewed by upstream maintainers.

## Public product links

- [CodeVetter](https://codevetter.com/)
- [Download](https://codevetter.com/download)
- [Documentation](https://codevetter.com/docs/)
- [Source](https://github.com/Codevetter/codevetter)
