Update LICENSE + CI build-speed and reliability fixes#107
Merged
Conversation
(from the github templates)
The prebuilt cabal-store tag is keyed on sha256(volca.cabal + mumps-hs.cabal + cabal.project). Because volca.cabal carries the `version:` line, every release bump changed the hash and missed the store — so cutting vX.Y.Z forced a full 5-platform re-prebuild even though the version has zero effect on the dependency closure. Strip version/synopsis/description before hashing, identically in the _build-matrix.yml probe and the prebuild-cabal-store.yml publish step, so the store survives release bumps. (This change itself shifts the hash once; re-run prebuild-cabal-store.yml to publish under the new tag.)
On macOS the GHCup cache key hit but the restore exceeded the
actions/cache timeout ("operation cannot be completed in timeout"),
so every run fell back to a cold 4-5 min GHC reinstall — the single
largest macOS time sink, defeating the cache entirely.
Drop the parts of ~/.ghcup that aren't needed to build a non-profiled
binary (install tarballs, unpack scratch, GHC docs, profiling libs)
right after install, shrinking the tree enough to restore in time.
Bump the cache key to v5 so the next save captures the lean tree.
volca's ~100 modules were compiled at -O2 on every CI run, including the PR smoke build that only needs to pass tests — the bulk of the remaining macOS build time after the cache fixes. Make the level a per-package override: gen-cabal-config.sh keeps the global `optimization: 2` (so the prebuilt store's deps still match) and sets volca itself from VOLCA_OPT_LEVEL (default 2). _build-matrix.yml exports 1 for PR builds and 2 for release builds, where the packaged binary is produced. Docker and local builds are unchanged (default 2). The redundant hardcoded -O2 is dropped from volca.cabal — it would have overridden the per-package setting (ghc-options beat the project flag).
The MUMPS and cabal-store probes piped `gh release view 2>/dev/null` straight into grep, so a flaky API call produced empty output and was read as "asset absent" — silently downgrading the job to the cold source build. Observed on macos-arm64, which reported the MUMPS asset missing 3 hours after the prebuild had published it. Query through a small retry helper that distinguishes a successful lookup (asset genuinely absent -> fall back, as before) from a failed lookup (retry, then fall back loudly). A real new-platform miss still returns instantly; only an erroring/absent release pays the retries.
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.
Started as a
LICENSErefresh (so the GitHub API reports the right license); now also carries four CI fixes that came out of profiling the macOS build (~20 min onmacos-arm64, ~16 min onmacos-intel).LICENSE
LICENSEfile.CI build-speed & reliability (one commit each)
1. Exclude
version/synopsis/descriptionfrom the cabal-store hash (086e507)The prebuilt cabal-store tag is keyed on
sha256(volca.cabal + mumps-hs.cabal + cabal.project). Becausevolca.cabalcarries theversion:line, every release bump changed the hash and missed the store — so cuttingvX.Y.Zforced a full 5-platform re-prebuild even though the version has no effect on the dependency closure. The filter is kept byte-identical in the_build-matrix.ymlprobe and theprebuild-cabal-store.ymlpublish step.2. Slim
~/.ghcupbefore caching → fixes the macOS restore timeout (b14967a)The single biggest macOS sink: the GHCup cache key hit but the restore exceeded the actions/cache timeout (
operation cannot be completed in timeout), so every run fell back to a cold ~4-5 min GHC reinstall. We now drop the bytes not needed to build a non-profiled binary (install tarballs, unpack scratch, GHC docs, profiling libs) and bump the key to-v5.3. Compile volca at
-O1for PR builds, keep-O2for shipped artifacts (6458c15)volca's ~100 modules were compiled at
-O2on every run, including the PR smoke build. Optimization becomes a per-package override ingen-cabal-config.sh: globaloptimization: 2stays (so the prebuilt store's deps still match) while volca itself followsVOLCA_OPT_LEVEL(default 2)._build-matrix.ymlexports1for PR builds,2for release builds (where the packaged binary is produced). Docker and local builds are unchanged.4. Don't mistake a transient
ghAPI error for a missing prebuilt asset (ed4e975)The MUMPS and cabal-store probes piped
gh release view 2>/dev/nullintogrep, so a flaky API call read as "asset absent" and silently dropped the job to the cold source build (observed onmacos-arm64reporting the MUMPS asset missing 3 h after it was published). Probes now go through a retry helper that separates a genuine absence from a query failure.After merge
prebuild-cabal-store.ymlto publish under the new hash17491f85(covers0.6.1.0and0.7.0alike). NoCABAL_PREBUILT_REVISIONbump needed.