From 4354000e3391af9a45a8a64ffc7ca7e5afcc033f Mon Sep 17 00:00:00 2001 From: Michael Bradley Date: Sun, 23 Feb 2025 07:35:40 -0500 Subject: [PATCH] Set up venv --- .forgejo/workflows/build.yaml | 10 ++++++++-- 1 file changed, 8 insertions(+), 2 deletions(-) diff --git a/.forgejo/workflows/build.yaml b/.forgejo/workflows/build.yaml index 4c57e3f..d12bb9f 100644 --- a/.forgejo/workflows/build.yaml +++ b/.forgejo/workflows/build.yaml @@ -44,10 +44,16 @@ jobs: python-version: "3.13" cache: pip - name: Set up the Python environment - run: pip install -r requirements.txt + # For most Python CI stuff this isn't needed, but maturin specifically doesn't like to function without a venv + run: | + python3 -m venv venv + source venv/bin/activate + pip install -r requirements.txt - name: Build Rust code run: maturin develop - name: Run Python tests - run: pytest tests/*.py + run: | + source venv/bin/activate + pytest tests/*.py - name: Run Rust tests run: cargo test