Choose the command for your Linux distribution:
Ubuntu, Debian, and Mint:
sudo apt update
sudo apt install -y gitFedora:
sudo dnf install -y gitArch Linux:
sudo pacman -S sudo
sudo pacman -S git
sudo pacman -S opensshIf your Arch install does not have sudo configured yet, run the commands above as root, then configure sudo for your user.
After forking the repository on GitHub, clone your fork.
Use SSH if your SSH keys are set up:
git clone git@github.com:[YOUR_GITHUB_USERNAME]/malariagen-data-python.git
cd malariagen-data-pythonUse HTTPS if you prefer, or if you do not have SSH keys configured (common on WSL):
git clone https://github.com/[YOUR_GITHUB_USERNAME]/malariagen-data-python.git
cd malariagen-data-pythonChoose the command for your Linux distribution:
Ubuntu, Debian, and Mint:
sudo apt update
sudo apt install -y pipx
pipx ensurepathFedora:
sudo dnf install -y pipx
pipx ensurepathArch Linux:
sudo pacman -S python-pipx
pipx ensurepathClose and reopen your terminal to apply PATH changes. If you prefer to reload the shell in-place, run:
exec bashThe package requires >=3.10,<3.13. We use Poetry's built-in installer to handle the Python version universally across all distributions.
pipx install poetry
poetry python install 3.12poetry env use 3.12
poetry install --extras devpipx install pre-commit
pre-commit installRun pre-commit checks manually:
pre-commit run --all-filesRun fast unit tests using simulated data:
poetry run pytest -v tests/anophTo run legacy tests which read data from GCS, you'll need to request access to MalariaGEN data on GCS.
Once access has been granted, install the Google Cloud CLI:
./install_gcloud.shThen obtain application-default credentials:
./google-cloud-sdk/bin/gcloud auth application-default loginOnce authenticated, run legacy tests:
poetry run pytest --ignore=tests/anoph -v testsTests will run slowly the first time, as data will be read from GCS and cached locally in the gcs_cache folder.