Skip to content
Closed
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
40 changes: 23 additions & 17 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -16,22 +16,26 @@ env:
jobs:
checks:
name: Check Python ${{ matrix.python-version }} on ${{ matrix.os }}
env:
IGNORE_CONDA: true
runs-on: ${{ matrix.os }}
env:
UV_PYTHON: ${{ matrix.python-version }}
defaults:
run:
shell: bash
strategy:
matrix:
os: [ ubuntu-20.04, macos-latest, windows-latest ]
python-version: [ "3.9", "3.10", "3.11", "3.12" ]
os: [ ubuntu-22.04, macos-latest, windows-latest ]
python-version: [ "3.10", "3.11", "3.12" ]

Copilot AI Mar 30, 2026

Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

CI no longer tests Python 3.9, but pyproject.toml declares requires-python = ">=3.9" (and classifiers include 3.9). Either add 3.9 back to the matrix or update the project metadata/support policy to match, otherwise we may ship regressions for a still-supported version.

Suggested change
python-version: [ "3.10", "3.11", "3.12" ]
python-version: [ "3.9", "3.10", "3.11", "3.12" ]

Copilot uses AI. Check for mistakes.
fail-fast: true
steps:
- uses: actions/checkout@v4
with:
fetch-depth: 0

- uses: actions/setup-python@v5
with:
python-version: ${{ matrix.python-version }}
- uses: astral-sh/setup-uv@v7

- name: Install Python ${{ matrix.python-version }}
run: uv python install ${UV_PYTHON}

# Use msmpi on windows
- uses: mpi4py/setup-mpi@v1
Expand All @@ -49,28 +53,30 @@ jobs:
run: |
brew install libomp llvm

- name: Upgrade pip
run: |
python3 -m pip install -U pip
- name: Synchronize project environment
run: uv sync --locked --extra dev --extra matnormal --extra examples

Copilot AI Mar 30, 2026

Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The PR description says CI should run uv sync with --frozen to ensure the checked-in uv.lock is authoritative. This workflow currently uses uv sync --locked ..., which can still succeed even if the lockfile is out of date. Consider adding --frozen (optionally alongside --locked) so CI fails when pyproject.toml and uv.lock diverge.

Copilot uses AI. Check for mistakes.

- name: Run tests and other checks
- name: Run static analysis and tests
if: runner.os == 'Linux'
run: |
./pr-check.sh
uv run ./run-checks.sh
uv run ./run-tests.sh --sdist-mode
uv run bash -lc 'cd docs && make'
Comment on lines +63 to +64

Copilot AI Mar 30, 2026

Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

run-tests.sh --sdist-mode disables the script’s editable-installation check (per the comment in run-tests.sh). Since uv.lock pins brainiak as an editable source, consider running ./run-tests.sh without --sdist-mode (or adjusting the script’s detection) so CI still verifies the intended install mode.

Copilot uses AI. Check for mistakes.

- name: Run tests and other checks
- name: Run static analysis and tests
if: runner.os == 'macOS'
run: |
export CLANG_PREFIX=$(brew --prefix llvm)
export CC=$CLANG_PREFIX/bin/clang
export CXX=$CLANG_PREFIX/bin/clang++
./pr-check.sh
uv run ./run-checks.sh
uv run ./run-tests.sh --sdist-mode
uv run bash -lc 'cd docs && make'

# On window, just install the package and run tests for now, we need to port the pr-check script to windows
# On Windows, just install the package and run tests for now, we need to port the pr-check script to windows
- name: Run tests and other checks
if: runner.os == 'Windows'
run: |
python -m pip install .[all] -v
python -m pytest -v
uv run python -m pytest -v

# - uses: codecov/codecov-action@v1
1 change: 1 addition & 0 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
src/brainiak/_version.py

venv/
.venv/

*.iml
*.eggs
Expand Down
Loading
Loading