chore(ci): derive workflow matrices from the root workspaces list - #5638
Draft
svozza wants to merge 1 commit into
Draft
chore(ci): derive workflow matrices from the root workspaces list#5638svozza wants to merge 1 commit into
svozza wants to merge 1 commit into
Conversation
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.
Summary
Three workflows hardcoded which packages to lint, unit-test and e2e-test, while the layer build and release gate already derived their lists from the root
workspaces. This PR makes CI read the same source, so adding a workspace to the rootpackage.jsonis all a new package needs. Deriving the list surfaced thatpackages/signerwas absent from the unit-test matrix and had never had a unit-test job in CI.Changes
.github/scripts/list_workspaces.js, which lists non-privatepackages/*workspaces, workspaces with e2e suites, or workspaces with LMI suites as a sorted JSON array. It fails loudly on glob workspace patterns, empty results, and workspaces whose e2e suites lack the script the matrix job runs. It is written as ESM and depends on Maintenance: convert the scripts in.github/scriptsto ESM #5639 converting.github/scriptsto ESM; until that lands theresolve-workspacesjob fails on theimportsyntax.reusable-run-linting-check-and-unit-tests.yml: newresolve-workspacesjob feeds thecode-qualitymatrix throughfromJSON; theunit-tests-completeaggregate also depends on it so a resolver failure is reported rather than passing as nothing ran.run-e2e-tests.yml: same resolver drives both the utilities and LMI matrices. Both reproduce the previous hardcoded lists exactly.quality_check.yml: now calls the reusable workflow instead of carrying a second, drifted copy of the matrix. It listens tomerge_groupand so becomes active once merge queues are enabled, reporting the samerun-unit-tests / unit-tests-completecontext that branch protection already requires.packages/signer:test:unit:typespointed at atests/typesdirectory that does not exist and always failed; it now uses the sameecho 'Not Implemented'placeholder as the other packages without type tests.docs/maintainers.md: the new-package checklist now says to add the workspace to the rootpackage.jsonand nothing else.Not in scope:
publish-package.ymlstill hardcodes a stale package choice list, has never run, and usesNPM_TOKEN; it should be removed or repaired separately. The roottsconfig.jsonreferenceslist has also drifted and is a separate fix.Blocked by: #5639
Issue number: closes #5637
By submitting this pull request, I confirm that you can use, modify, copy, and redistribute this contribution, under the terms of your choice.
Disclaimer: We value your time and bandwidth. As such, any pull requests created on non-triaged issues might not be successful.