fix(ci): pin pip <26.1 in Tiny AI workflow (lightning regression)#231
Merged
fix(ci): pin pip <26.1 in Tiny AI workflow (lightning regression)#231
Conversation
…ression
pip 26.1 (released 2026-04-30) regresses transitive resolution for
`lightning>=2.5,<3.0` and fails the `pip install -e ai` step in the
Tiny AI workflow with:
ERROR: Could not find a version that satisfies the requirement
lightning<3.0,>=2.5 (from vmaf-train) (from versions: none)
This blocks every PR's Tiny AI gate. Concrete cases observed:
- PR #213 same-SHA reruns: 12:41 UTC pass (pip 24.0) → 15:54 UTC fail
(pip 26.1, after `pip install --upgrade pip` pulled the new release).
- PR #229 yesterday: passed with pip 24.0, lightning-2.6.1 resolved
cleanly.
The PR diff itself doesn't touch `ai/`, so this is purely an upstream
pip regression breaking a working workflow.
Pin to `pip<26.1` in the Tiny AI venv until pip ships a fix. Other
workflows that don't depend on `lightning` resolution are left alone
to keep this change narrow.
Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
…ghtning Initial pin `pip<26.1` was insufficient: pip 26.0.1 has the same "No matching distribution for lightning<3.0,>=2.5" regression as 26.1. Verified on this PR's own run (job 73817357146): venv installed pip-26.0.1 (under 26.1), then `pip install -e ai` failed identically. The runner image ships pip 24.0 pre-installed (PR #229 baseline, 2026-04-29, succeeded). Drop the `--upgrade pip` line so the venv inherits 24.0 and skips the broken 26.x release entirely. Re-introduce the upgrade once a pip release lands that resolves lightning correctly. Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
9 tasks
lusoris
added a commit
that referenced
this pull request
Apr 30, 2026
* fix(ai): switch lightning → pytorch-lightning (PyPI 404) Lightning AI un-published the `lightning` distribution from PyPI on 2026-04-30. Verified: $ curl -sSI https://pypi.org/pypi/lightning/json HTTP/2 404 $ curl -sSI https://pypi.org/pypi/pytorch-lightning/json HTTP/2 200 # version 2.6.1 — same wheel that pip resolved yesterday Yesterday's PR #229 successfully downloaded `lightning-2.6.1-py3-none-any.whl`; today every PR's Tiny AI gate fails with "No matching distribution found for lightning<3.0,>=2.5 (from versions: none)" — the resolver is correctly reporting the 404. PR #231's earlier `pip<26.1` pin was treating a misdiagnosis (pip resolver bug); the pin is harmless but unnecessary now and will be dropped in a follow-up. `pytorch-lightning >= 2.0` ships both `import lightning` and `import pytorch_lightning` entry points, so `import lightning as L` in ai/src/vmaf_train/{datamodule,train,models/*}.py and the train scripts continues to work without source changes. Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com> * fix(ai): migrate `import lightning` → `import pytorch_lightning` The previous commit on this branch swapped the PyPI distribution name (`lightning>=2.5,<3.0` → `pytorch-lightning>=2.5,<3.0`) under the incorrect assumption that pytorch-lightning ships both the `pytorch_lightning` and `lightning` import namespaces. CI proved otherwise: pytest collection errors on this branch with `ModuleNotFoundError: No module named 'lightning'` from ai/tests/test_export_roundtrip.py and ai/tests/test_registry.py (import-side test discovery; these import from vmaf_train). The pytorch-lightning distribution only exposes `pytorch_lightning` as a top-level import. The `lightning` shim was an exclusive of the now-404 `lightning` distribution. Migrated all six call sites: ai/src/vmaf_train/datamodule.py ai/src/vmaf_train/train.py (also `lightning.pytorch.callbacks` → `pytorch_lightning.callbacks`) ai/src/vmaf_train/models/fr_regressor.py ai/src/vmaf_train/models/nr_metric.py ai/src/vmaf_train/models/learned_filter.py ai/scripts/train_konvid.py (same callbacks rename) API surface is unchanged — pytorch_lightning >= 2.0 has the same LightningModule / LightningDataModule / Trainer / callbacks API as the lightning distribution did. Updated the pyproject comment to reflect the namespace reality. Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com> --------- Co-authored-by: Lusoris <lusoris@pm.me> Co-authored-by: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
7 tasks
lusoris
pushed a commit
that referenced
this pull request
May 1, 2026
PR #231 pinned `pip<26.1` under the assumption that pip 26.x had a resolver regression breaking `lightning>=2.5,<3.0` lookup. Confirmed in #232 that the actual root cause was Lightning AI un-publishing the `lightning` distribution from PyPI on 2026-04-30 — pip was correctly reporting a 404. PR #232 swapped the dep to `pytorch-lightning` and the gate is green again. The pin is therefore harmless cruft. Restore the `--upgrade pip` step so the venv tracks the latest pip, matching the convention in every other workflow in this repo. No functional change beyond removing the diagnostic comment block. Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
lusoris
added a commit
that referenced
this pull request
May 1, 2026
PR #231 pinned `pip<26.1` under the assumption that pip 26.x had a resolver regression breaking `lightning>=2.5,<3.0` lookup. Confirmed in #232 that the actual root cause was Lightning AI un-publishing the `lightning` distribution from PyPI on 2026-04-30 — pip was correctly reporting a 404. PR #232 swapped the dep to `pytorch-lightning` and the gate is green again. The pin is therefore harmless cruft. Restore the `--upgrade pip` step so the venv tracks the latest pip, matching the convention in every other workflow in this repo. No functional change beyond removing the diagnostic comment block. Co-authored-by: Lusoris <lusoris@pm.me> Co-authored-by: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
lightning>=2.5,<3.0— thepip install -e aistep in the Tiny AI workflow now fails withNo matching distribution found for lightning<3.0,>=2.5on every PR.lightning-2.6.1resolved fine). PR feat(upstream): port d3647c73 — feature/speed extractors (speed_chroma + speed_temporal) #213 passed at 12:41 UTC today, then failed twice on reruns at 15:05 and 15:54 UTC afterpip install --upgrade pippulled 26.1.pip<26.1only in the Tiny AI venv. Other workflows don't needlightningresolution and are left alone.Six-deliverable checklist (ADR-0108)
lightninginai/pyproject.tomldoes not work around the resolver bug).Reproducer
Failing path (current master, after pip 26.1 release):
Fixed path (this PR):
Test plan
Notes
No ai/pyproject.toml change —
lightning>=2.5,<3.0is a valid constraint that pip ≤25.x and pip ≥26.2 (once shipped) should resolve. This is a CI-infra mitigation, not a dep change.