A Python reusable action's dependencies are made available by the Python runtime. Consequently, setting up a local development environment involves installing global production dependencies (from the Python runtime's repo) as well as local development dependencies (from this repo).
First, create and activate a new Python 3.8 virtual environment:
python3 -m venv .venv
source .venv/bin/activateInstall pip-tools:
pip install pip-toolsUpdate requirements.dev.txt, resolving global production dependencies and local development dependencies:
pip-compile --generate-hashes --output-file=requirements.dev.txt requirements.dev.inFinally, synchronise the local development environment:
pip-sync requirements.dev.txtFor more information about dependencies and the Python runtime, see https://docs.opensafely.org/actions-reusable/.
make test