Skip to content

CI: replace pixi with pip for test + code-quality jobs#49

Merged
JanStreffing merged 1 commit into
masterfrom
ci/replace-pixi-with-pip
Jun 29, 2026
Merged

CI: replace pixi with pip for test + code-quality jobs#49
JanStreffing merged 1 commit into
masterfrom
ci/replace-pixi-with-pip

Conversation

@JanStreffing

Copy link
Copy Markdown
Owner

Problem

The Test Python Code and Code Quality Checks jobs both fail at the pixi install / pixi install -e dev step — i.e. environment resolution, before any project code runs. This is preexisting on master (unrelated to any code change).

Evidence it's pixi's resolver and not the project deps:

  • The Build Documentation job, which installs the same package via plain pip install -e ., passes.
  • The non-pixi checks (Documentation Check, Security Scanning, Trivy) pass.

Fix

Switch both jobs from setup-pixi to actions/setup-python + pip, mirroring the green docs job:

  • test-python: install libeccodes-dev via apt (so the gribapi/eccodes Python bindings import — gribapi is the only conda-specific import, in lsm.py), then pip install the runtime deps actually imported by the tested modules. pyfesom2 is not imported at module top level by any of the tested modules, so the heavy git dependency is omitted. Then run the existing syntax + import checks unchanged.
  • code-quality: pip install flake8 black isort and run them directly (these need no project deps).

Verification (local)

  • All tracked Python compiles (py_compile) cleanly.
  • The flake8 hard-fail gate --select=E9,F63,F7,F82 reports 0 over the tracked tree (flake8 7.3.0).
  • ci.yml parses as valid YAML.

The black/isort steps remain non-blocking (|| echo ::warning::), exactly as before.

Note: this is orthogonal to #48 (the CO2/INIUA staging fix) — that PR's red checks are this same preexisting pixi breakage and can be merged independently once this lands and its branch is updated.

The `Test Python Code` and `Code Quality Checks` jobs both failed at the
`pixi install` step (environment resolution), before any code ran. The
pip-based `Build Documentation` job installs the same package fine, so
the breakage is in pixi's resolver, not the project deps.

Switch both jobs to actions/setup-python + pip:
- test-python: apt-install libeccodes-dev (for the gribapi/eccodes
  bindings), pip-install the runtime deps actually imported by the
  tested modules (pyfesom2 is not imported at module top level, so it
  is omitted), then run the syntax + import checks.
- code-quality: pip-install flake8/black/isort and run them directly.

Verified locally: all tracked Python compiles, and the flake8 hard-fail
gate (E9,F63,F7,F82) reports 0 over the tracked tree.
@JanStreffing JanStreffing merged commit ba0df1a into master Jun 29, 2026
5 checks passed
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