Repository navigation
CI: test-python-examples builds the JVM wheel once for each platform - #99
Merged
Merged
Conversation
Since #92 the JVM wheel is py3-none-<platform>, the same file for every Python, but each of the 16 legs of test-python-examples.yml still built it. On push to main, the nightly run, dispatch and the release that was 16 identical builds, 12 of them wasted on macOS, Windows and Linux runners the organisation shares with ArcadeData/arcadedb. A `build` job now builds the wheel once for each platform (select_matrix.py examples --wheels, the shape of test-jvm.yml), checks the tag, and uploads it as examples-wheel-<platform> (not wheel-<platform>: release-jvm.yml publishes every wheel-* artifact, and the release runs both workflows in one run). Each Test Python Examples leg downloads the wheel of its platform and installs it; it no longer sets up Java or Docker Buildx, downloads the jars, or installs build tools. The leg names, the examples matrix (newest Python on each platform on a pull request, 16 legs otherwise) and the examples run are unchanged. build.sh still checks the size, licences and tag of the wheel; the tag check is repeated in the job as in test-jvm.yml. Counts in ci.adoc and CLAUDE.md follow: a pull request runs 28 checks (was 24), the other events 40 (was 36). A new test pins the build job, the wheel download and the artifact name. Co-Authored-By: Claude Sonnet 5.5 <[email protected]>
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.
Since #92 the JVM wheel is
py3-none-<platform>, the same file for every Python, andtest-jvm.ymlbuilds it once for each platform.test-python-examples.ymlstill built it in each of its legs. This PR gives it the samebuildjob and a per-leg download.Build count
py3-none, 12 of them identical repeats)Build wheel for examples (<platform>)job in front of each leg)On a pull request the number of builds does not change, because the examples already run one Python for each platform there. What changes on a pull request is that the build moves into its own job, so there are 4 more jobs; each leg no longer sets up Java or Docker Buildx, downloads the jars or installs build tools. If the extra job per platform costs more queueing than it saves on pull requests, say so and I will build inline for that event.
What changes
download-jarsalso outputswheel-matrix(scripts/select_matrix.py examples --event ... --wheels, which already existed).buildjob, one leg for each platform: it runsscripts/build.sh, which checks size, licences and tag, thenscripts/verify_wheel_tag.pyagain (as intest-jvm.yml, so the tag shows in the log and summary), and uploads the wheel asexamples-wheel-<platform>(1 day). The scripts are called, not copied.Test Python Examples (<platform>, Python <version>)downloads the wheel of its platform and installs it. Leg names, the examples matrix (newest Python on each platform on a pull request, 16 legs on the other events) and the examples that run are unchanged.Examples Test Summaryalso needsbuild.examples-wheel-*, notwheel-*: the release calls both workflows in one run,release-jvm.ymldownloadswheel-*and expects exactly four wheels, and two uploads of the same name would collide.ci.adoc(one sentence, plus the check counts), the same counts inCLAUDE.md: a pull request runs 28 checks (was 24), the other events 40 (was 36). The counts come from the matrices, not from memory.tests/test_select_matrix.pygets a test for the examples workflow like the one fortest-jvm.yml: the--wheelsmatrix, no Python in the build job,build.shonly there, the wheel download in the leg, and nowheel-*artifact name.Not done
test-jvm.ymland this workflow each build the same wheel for a commit, so a push to main builds 8 wheels, not 4. Sharing one build between the two workflows would need a reusable workflow or a combined one; I left that out of this change.Checked
download-jars->build->test-examples->test-examples-summary.python3 scripts/check_no_embedded_name.py --root .: ok.tests/test_select_matrix.py,test_check_version.py,test_release_name_guards.py,test_select_native_matrix.py,test_no_embedded_name.py: 109 passed.🤖 Generated with Claude Code