Repository navigation
Speed up CI runs - #902
Merged
Merged
Speed up CI runs#902
Conversation
The test command ran "pip install '.[test]'" from the project directory. pip builds a local directory from source, so every test run uninstalled the repaired wheel, compiled the extension again and tested that build instead. The shipped wheels were never tested, and the rebuild took 45-100 s for each CPython version on each platform. Install the test dependencies with CIBW_TEST_EXTRAS instead, and keep preferring binary wheels for them with PIP_PREFER_BINARY. Assisted-by: Claude Opus 5.5
The macOS, Windows and sdist cache keys hashed .git/modules/**/HEAD. That glob also matches the submodule reflog logs/HEAD, which contains checkout timestamps, so the key changed on every run: the C core was rebuilt each time and a new cache entry was saved. Hash only the submodule's HEAD file, as the sanitizer job already does. Assisted-by: Claude Opus 5.5
The two cibuildwheel steps ran one after the other in one job, which made it the slowest job in the workflow. Split it in two, as the aarch64 builds already are. Assisted-by: Claude Opus 5.5
The three Pyodide wheels each rebuild the C core with their own Emscripten version and took about 6 minutes each, one after the other. Build them in parallel with a matrix over the CPython versions. Assisted-by: Claude Opus 5.5
There was a problem hiding this comment.
🟢 Approval recommended
No active review issues are reported for the CI build and wheel-testing changes.
No open issues 🎉
What changed in this PR
This PR aims to shorten igraph’s CI runs by parallelizing wheel builds and avoiding source rebuilds during wheel testing.
Changes:
- Split Linux x86_64 builds into separate manylinux and musllinux jobs, and run WebAssembly builds in a Python-version matrix.
- Install test dependencies through cibuildwheel extras, preserving the built wheel under test and preferring binary dependencies.
- Narrow C-core cache hashing to the igraph submodule’s
HEADfile.
| File | Description |
|---|---|
.github/workflows/build.yml |
Parallelizes build jobs, updates artifact names, streamlines test dependency installation, and refines C-core cache keys. |
Review effort: Balanced
The sdist command copies the generated parser sources from vendor/build, but the sdist job only cached vendor/install. This went unnoticed because the cache key never matched before. Now that it does, a cache hit skipped the C core build and sdist failed. Cache vendor/build as well, under a new key, as the sanitizer job already does. Assisted-by: Claude Opus 5.5
ntamas
approved these changes
Nov 29, 2026
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.
Speed up CI runs. Point 2 is a fix, but do check the others please.