Repository navigation
ci(android): restore the ndk and emulator image from the actions cache - #1003
Merged
Merged
Conversation
sdkmanager unzips a download without checking its length. two setup-android runs failed when the dl.google.com transfer ended early (ndk at 20%, the api 37 image at 26% of the download phase) and the unzip read a truncated zip. pushes now save each installed package keyed on its package id and revision, and every job restores it before setup-android, which skips an installed package; on a miss sdkmanager downloads it as before. Validation: pending this branch's Android Native Build runs Team-Machine-Session: p100604
the ndk writes "Pkg.Revision = 27.1.12297006" while system images write "Pkg.Revision=6", so the ndk was saved under a key with no revision. Validation: sed read 27.0.12077973 and 6 from local ndk and system image source.properties Team-Machine-Session: p100604
pr 1003's own run then failed the same way on the emulator package, so the cache now holds each job's whole package list, the same list setup-android installs. a hit replaces the runner image's copies of those packages whole. Validation: pending this branch's dispatch runs Team-Machine-Session: p100604
Validation: actionlint and git diff --check passed. Read root/app/One Gradle NDK settings and WebGPU Gradle source; run 39684736046 compile log confirms Gradle installed 28.2.13676358 while 27.1.12297006 remains the root pin. Runtime save/restore proof pending. Team-Machine-Session: r116388
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.
Three Android Native Build setups failed in
android-actions/setup-android@v4before any test ran, withError reading Zip content from a SeekableByteChannel:ndk;27.1.12297006system-images;android-37.0;google_apis;x86_64In all three logs the download phase stops early and jumps to its end (NDK at 20%, the image at 26% and 11%; a good run climbs steadily to 33%), and the unzip fails within 0.2s. sdkmanager unzipped a truncated transfer from dl.google.com without checking its length. Each run downloads the 663 MB NDK zip once and the 2.2 GB image zip in each of the six fixture shards.
This adds a small composite action that restores one installed SDK package before setup-android and, on pushes only, saves it afterwards, keyed on the package id and the installed
Pkg.Revision. setup-android passes the same package list as before; sdkmanager skips an installed package and downloads it exactly as today on a cache miss, so a missing package still fails setup. Pull requests read the main cache, like the gradle cache.Cache budget: the repo sits at 10.36 GB of 10 GB, but the entries current runs touch total about 5.8 GB; the rest are stale PR and branch copies that LRU eviction drops first. The two packages add roughly 2.9 GB.
No test, predicate or budget changes.