Repository navigation
Measure changes from rc and build pull requests on fewer entries - #33
Merged
Merged
Conversation
ci/packages.ps1 chose the products a pull request touches from its diff with main. A pull request into rc is checked out with rc merged in, so that diff also held every change on rc not yet on main, which included pipeline/ and so selected every product for every pull request until the next release. And every pull request ran all 15 configurations, five on macOS, of which only five run at once across the organisation. - Get-AffectedProducts takes the branch the pull request merges into, which common-ci passes as Branch and every root step now declares. - ci/select-options.ps1 chooses the configurations for common-ci. The standard set is Python 3.14 and 3.10 on Linux, with the Selenium contract on 3.14 alone. A change to an on-premise package, its data or the cxx submodule adds Windows, a packaging change adds 3.11 to 3.13 on Linux, and a change outside the product folders or to a ci folder adds every configuration but macOS. macOS and performance run only when rc itself or a release is built. - The Pull Requests workflow lets one failure leave the other configurations running, and builds nothing when no pull request is eligible. The nightly publishes before it builds pull requests, as the publish builds main, and starts at 05:00 rather than 03:00, when the Java and Node nightlies also started and wanted macOS runners. - The release pull request from rc into main is built on every configuration. These need common-ci's fail-fast, full-matrix and build-without-pull-requests inputs and its release-pull-request.yml on common-ci main before this reaches main.
# Conflicts: # ci/dispatch.ps1
… folder the monorepo no longer has
…s of entries, which share their names
jwrosewell
marked this pull request as ready for review
November 13, 2026 22:30
jwrosewell
added a commit
that referenced
this pull request
Nov 14, 2026
The scripts in `ci/` decide what a pull request builds and what a publish releases, and each has Pester tests beside it. `rc` holds five such files, being `ci/packages.Tests.ps1`, `ci/dispatch.Tests.ps1`, `ci/check-environment-variable-names.Tests.ps1`, `ci/get-next-package-version.Tests.ps1` from [#54](#54) and `ci/select-options.Tests.ps1` from [#33](#33). Only the environment variable name tests ran in a workflow. The rest ran only by hand or on a temporary branch, as [#47](#47), [#54](#54) and [#60](#60) each say under what remains, so a change to the release plan or the dispatcher could break them unseen.
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.
Problem
ci/packages.ps1works out the products a pull request touches from its diff withmain. A pull request intorcis checked out withrcmerged in, so that diff also holds every change onrcnot yet released. On 4 Novemberrcwas 29 files ahead ofmain, includingpipeline/, and a change topipeline/touches every product, so every pull request selected every product until the next release.And a pull request into
rcruns all 15 configurations inci/options.json, five of them on macOS, of which only five run at once across the whole organisation.Cost, measured from run history
nightly-pipeline.ymlon each repository'smain, read at 18:20 UTC on 13 November), and all three want macOS runners.Change
Get-AffectedProductsinci/packages.ps1takes the branch the pull request merges into, which common-ci passes asBranch.ci/dispatch.ps1passes it on when it has no list of products, and every root step declares it. A publish or a build of the branch itself still selects every product.ci/select-options.ps1chooses the configurations for common-ci'ssteps/select-options.ps1, which common-ci#309 added and which is on common-ci'smainsince common-ci's release of 12 November. Within each configurationci/packages.ps1still runs only the products the change touches.Ubuntu_Python_3.14andUbuntu_Python_3.10, the newest and the oldest, with the Selenium contract on 3.14 alone.cxxsubmodule, in more than its comments, addsWindows_Python_3.14, where the native module is built differently. The data files come in throughcxx, so a change to them is a change tocxx.setup.py,setup.cfgorpyproject.tomladds Python 3.11 to 3.13 on Linux.cifolder adds every configuration but macOS.rcitself or a release is built do the five macOS configurations and the performance tests run.ci/run-integration-tests.ps1passes the Selenium choice todevice-detection/ci/run-integration-tests.ps1, which skips the contract whereSeleniumContractis false. It is true by default.fail-fast: falseandbuild-without-pull-requests: false, and gains afull-matrixbox for a full build of a pull request by hand.main, which the pull requests intorcdo not change. It starts at 05:00 rather than 03:00, after the Java and Node.js nightlies, and the schedule's comment says why.release-pull-request.ymlbuilds the release pull request fromrcintomainon every configuration, macOS included, through common-ci'srelease-pull-request.yml, as a dry run that merges nothing.ci/select-options.Tests.ps1is new. It reads the realci/options.jsonas common-ci does, as hashtables, and checks the choice for a package's code, an on-premise package,cxx, a change only to an on-premise file's comments, asetup.py, acifolder, the rootcifolder and a workflow file, that the Selenium contract runs on Python 3.14 alone with no performance tests, and that no pull request builds macOS.Expected saving
cxxsubmoduleThese use the publish test medians, which install the built packages and run the integration tests, so they are not the same work as a pull request build. Within each configuration the base fix also stops every product being built for a change to one.
How it was checked
rcat df0949d7 is merged in at 4cc8f18. The one conflict was inci/dispatch.ps1, whererchad givenInvoke-ProductStepa list of products to run, which the prefetch of assets uses, and this draft the branch to measure from. Both are kept, and the branch is used only when no list is given.ci/select-options.ps1. PowerShell names are not case sensitive, so the flag$nativeand the list of entries$Nativewere one variable, the list becameTrue, andTrue -contains <name>holds for every name, so any change to native code built all ten Ubuntu and Windows entries. Run 43480673571, at 6ce34bd, failedadds Windows for a change to an on-premise packageandadds Windows for a change to the cxx submoduleonubuntu-latestandwindows-latest,Tests Passed: 138, Failed: 2. Commit 2e8d370b renames the flags to$nativeChanged,$setupChangedand$otherChanged.Tests Passed: 140, Failed: 0. Both runs are temporary branches holding a workflow that checks out common-ci'smainbeside this repository and runs everyci/*.Tests.ps1with Pester.What it gives up
On a pull request, macOS, Windows unless native code changes, Python 3.11 to 3.13 unless the packaging changes, the Selenium contract on all but one configuration, and performance. A fault that shows only there is found by the nightly build of
rcor by the release pull request build, before anything reachesmain.Merge order and the full build tool
The coordinator's full build tool copies the
with:lines of this repository'spull-requests.ymlinto a temporary workflow that calls common-ci'snightly-pull-request.yml. Once this draft is onrc, it would copybuild-without-pull-requests: false, whichnightly-pull-request.ymldoes not take, andfull-matrix: ${{ inputs.full-matrix || false }}, which is false on a push, so every draft's full build would either fail to start or be cut down to the configurations the change needs. 51degrees-cxx#99 has the same lines. So this draft merges after the tool leavesbuild-without-pull-requestsout and passesfull-matrix: true, and after the full builds of the drafts that merge before it.What remains
rcafter this merges.The last release into
mainwas #114, merged at 06:22 UTC on 13 November.