Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion .pre-commit-config.yaml
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
# https://pre-commit.com/
repos:
- repo: https://github.com/pre-commit/pre-commit-hooks
rev: v4.5.0
rev: v6.0.0
hooks:
- id: trailing-whitespace
- id: end-of-file-fixer
Expand Down
47 changes: 34 additions & 13 deletions CONTRIBUTING.md
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,35 @@ You'll need:
- [pipx](https://pipx.pypa.io/) for installing Python tools
- [git](https://git-scm.com/) for version control

Both of these can be installed using your distribution's package manager or [Homebrew](https://brew.sh/) on Mac.
Both of these can be installed using your distribution's package manager or [Homebrew](https://brew.sh/) on Mac. On Windows we recommend development on Linux using [WSL2](https://learn.microsoft.com/en-us/windows/wsl/install). For example,

**Ubuntu, Debian, and Mint:**

```bash
sudo apt install -y git pipx
pipx ensurepath
```

**Fedora:**

```bash
sudo dnf install -y git pipx
pipx ensurepath
```

**Arch Linux:**

```bash
sudo pacman -S git pipx
pipx ensurepath
```

**Mac**

```bash
brew install git pipx
pipx ensurepath
```

### Initial setup

Expand Down Expand Up @@ -55,27 +83,20 @@ Both of these can be installed using your distribution's package manager or [Hom
poetry install --with dev,test,docs
```

This installs the runtime dependencies along with the `dev`, `test`, and `docs`
[dependency groups](https://python-poetry.org/docs/managing-dependencies/#dependency-groups).
This installs the runtime dependencies along with the `dev`, `test`, and `docs` [dependency groups](https://python-poetry.org/docs/managing-dependencies/#dependency-groups).
If you only need to run tests, `poetry install --with test` is sufficient.

**Recommended**: Use `poetry run` to run commands inside the virtual environment:
You can use `poetry run` to run commands inside the virtual environment:

```bash
poetry run pytest
poetry run python script.py
```

**Optional**: If you prefer an interactive shell session, install the shell plugin first:

```bash
poetry self add poetry-plugin-shell
```

Then activate the environment with:
Alternatively, if you prefer an interactive shell session, activate the environment using:

```bash
poetry shell
eval $(poetry env activate)
```

After activation, commands run directly inside the virtual environment:
Expand Down Expand Up @@ -147,7 +168,7 @@ Both of these can be installed using your distribution's package manager or [Hom
poetry run pytest -v tests/integration
```

Tests will run slowly the first time, as data required for testing will be read from GCS. Subsequent runs will be faster as data will be cached locally in the "gcs_cache" folder.
Tests will run slowly the first time, as data required for testing will be read from GCS. Subsequent runs will be faster as data will be cached locally in the `gcs_cache` folder.

6. **Run typechecking**

Expand Down
140 changes: 0 additions & 140 deletions LINUX_SETUP.md

This file was deleted.

77 changes: 0 additions & 77 deletions MACOS_SETUP.md

This file was deleted.

5 changes: 0 additions & 5 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -46,11 +46,6 @@ for release notes.

To get setup for development, see [this video if you prefer VS Code](https://youtu.be/zddl3n1DCFM), or [this older video if you prefer PyCharm](https://youtu.be/QniQi-Hoo9A).

For detailed setup instructions, see:
- [Linux setup guide](LINUX_SETUP.md)
- [macOS setup guide](MACOS_SETUP.md)
- [Windows setup guide](WINDOWS_SETUP.md)
- [Google Colab (TPU) setup guide](docs/source/colab_tpu_runtime.rst)
Detailed instructions can be found in the [Contributors guide](https://github.com/malariagen/malariagen-data-python/blob/master/CONTRIBUTING.md).

## AI use policy and guidelines
Expand Down
Loading
Loading