Skip to content

ci: install the declared test group in the conda job - #1375

Merged
Marius1311 merged 1 commit into
mainfrom
ci/conda-job-test-group
Aug 24, 2026
Merged

ci: install the declared test group in the conda job#1375
Marius1311 merged 1 commit into
mainfrom
ci/conda-job-test-group

Conversation

@Marius1311

Copy link
Copy Markdown
Collaborator

Stacked on #1371 — GitHub retargets this to main once that merges.

Problem

The PETSc / SLEPc + R job hand-rolls its test dependencies in the workflow:

pip install pytest pytest-cov pytest-mock pytest-timeout coverage igraph leidenalg pillow

Every other job installs the test dependency group from pyproject.toml, so the two drifted in both directions:

  • leidenalg is dead weight. It appears exactly once in the repo — that line. _cluster_X pins sc.tl.leiden(..., flavor="igraph") and the plotting tests pass clustering_kwargs={"flavor": "igraph"}, so only igraph (already in the group) is ever needed. It was added in CI workflow modernization #1291 (Feb 2026).
  • pytest-timeout is missing from the group, even though it is a real test dependency — the conda job runs pytest --timeout=600, and hatch test -- --timeout=… fails locally because the hatch envs don't have it.

Changes

  • Declare pytest-timeout in the test dependency group.
  • Install that group in the conda job: pip install -e '.[plot]' --group test (pip on the runner is 26.2.1; --group needs ≥ 25.1).

This matches cookiecutter-scverse, whose test workflow installs declared groups only (hatch env create + hatch run …:run-cov) and never an ad-hoc package list.

Note the conda job now also gets jax, moscot and scvelo from the group, so the tests that currently skip there run under the PETSc/SLEPc + R stack too — more coverage, at the cost of a somewhat longer install.

🤖 Generated with Claude Code

Base automatically changed from ci/fix-zarr-pin-accept-macos-gpcca to main August 24, 2026 10:57
The PETSc/SLEPc + R job hand-rolled its test dependencies in the workflow instead of
using the `test` dependency group every other job installs, so the two drifted: the
list carried `leidenalg`, which nothing uses (cellrank pins `flavor="igraph"` in
`_cluster_X`, and the plotting tests pass the same flavor), while `pytest-timeout` —
which that job's `--timeout=600` needs — was missing from the group.

Add `pytest-timeout` to the group and install it with `pip install -e '.[plot]'
--group test`, matching the cookiecutter-scverse layout where CI installs declared
groups and never ad-hoc package lists.

Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
@Marius1311
Marius1311 force-pushed the ci/conda-job-test-group branch from f67c451 to de74fa9 Compare August 24, 2026 10:57
@Marius1311
Marius1311 merged commit 6a9ebe7 into main Aug 24, 2026
10 checks passed
@Marius1311
Marius1311 deleted the ci/conda-job-test-group branch August 24, 2026 11:32
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant