A package for installing fully-specified Python packages.
mousebender.simple
-- Parsers for the simple repository API
The goal is to provide a package which could install all dependencies as frozen by a tool like pip-tools via an API (or put another way, what is required to install pip
w/o using pip itself?). This avoids relying on pip's CLI to do installations but instead provide a programmatic API. It also helps discover any holes in specifications and/or packages for providing full support for Python package installation based on standards.
- Figure out what packages are necessary
- For an app, read lock file (?)
- For a package:
- Read list of dependencies (?)
- Solve dependency constraints (ResolveLib)
- Get the wheel to install
- Check if package is already installed (spec / importlib-metadata)
- Check local wheel cache (?; how pip does it)
- Choose appropriate file from PyPI/index
- Process the list of files (simple repository API / mousebender.simple)
- Calculate best-fitting wheel (spec / packaging.tags)
- If no wheel found ...
- Download the wheel
- Cache the wheel locally (?)
- Install the wheel
- Install the files (spec / distlib.wheel, installer)
- Record the installation (spec / ?)
The customer from Monty Python's cheese shop sketch is named "Mr. Mousebender". And in case you don't know, the original name of PyPI was the Cheeseshop after the Monty Python sketch.