@@ -27,8 +27,8 @@ From a high-level, the Commit Queue works as follows:
2727 workflow uses a five-minute cron, but GitHub Actions scheduled workflows are
2828 not guaranteed to run exactly every five minutes. For each candidate, the
2929 queue will:
30- 1 . Run a metadata-only readiness check that uses ` @node-core/utils ` without
31- checking out the repository
30+ 1 . In the landing job, install and configure ` @node-core/utils ` , then run a
31+ metadata-only readiness check without checking out the repository
3232 2 . If the metadata check exits with a deferrable readiness code, meaning
3333 the PR is only blocked on wait time, keep the ` commit-queue ` label and
3434 skip this PR until a later queue run
@@ -93,20 +93,20 @@ reasons:
9393 commit, meaning we wouldn't be able to use it for already opened PRs
9494 without rebasing them first.
9595
96- ` @node-core/utils ` is configured with a personal token and a Jenkins token from
97- [ @ nodejs-github-bot ] ( https://github.com/nodejs/github-bot ) . The workflow starts
98- with a small selector step that uses GitHub CLI to fetch pull requests with the
99- ` commit-queue ` label. It first fetches the same age-based and fast-track buckets
100- the queue used before accepting early queue requests, then fetches the broader
101- queue and de-duplicates the result. This keeps not-yet-ready PRs from crowding
102- out PRs that the previous query would have selected if GitHub paginates or caps
103- a query result.
104-
105- If there are candidate PRs, the selector installs ` @node-core/utils ` , downloads
106- the target branch's README without checking out the repository, and runs
96+ The workflow starts with a small candidate job that uses GitHub CLI to fetch
97+ pull requests with the ` commit-queue ` label. It first fetches the same
98+ age-based and fast-track buckets the queue used before accepting early queue
99+ requests, then fetches the broader queue and de-duplicates the result. This
100+ keeps not-yet-ready PRs from crowding out PRs that the previous query would
101+ have selected if GitHub paginates or caps a query result.
102+
103+ If there are candidate PRs, the landing job installs and configures
104+ ` @node-core/utils ` once with a personal token and a Jenkins token from
105+ [ @ nodejs-github-bot ] ( https://github.com/nodejs/github-bot ) . It then downloads
106+ the target branch's README without checking out the repository and runs
107107` git node metadata --readme --json ` for each candidate. This uses the same
108108` @node-core/utils ` PR readiness checks as ` git node land ` , but does not clone,
109- fetch, or merge the PR. The selector consumes the structured metadata result
109+ fetch, or merge the PR. The filter consumes the structured metadata result
110110and its exit code instead of matching human-readable output:
111111
112112* exit code ` 0 ` : the PR is ready and is passed to
@@ -119,12 +119,13 @@ and its exit code instead of matching human-readable output:
119119
120120The ` 20 ` -` 29 ` exit code range is reserved by ` @node-core/utils ` for deferrable
121121metadata readiness states, and ` 40 ` -` 49 ` is reserved for hard metadata failure
122- states. Unknown selector failures fail the workflow before starting the landing
123- job and leave PR labels unchanged so the queue can retry on a later scheduled
124- run. PRs passed through with exit code ` 40 ` -` 49 ` continue through
125- ` commit-queue.sh ` . The script still applies its existing ` request-ci ` and
126- pending-check deferrals before removing the queue label and reporting a hard
127- failure.
122+ states. Unknown filter failures fail the workflow before starting the landing
123+ script and leave PR labels unchanged so the queue can retry on a later
124+ scheduled run. PRs passed through with exit code ` 40 ` -` 49 ` continue through
125+ ` commit-queue.sh ` . The workflow checks out the repository only when at least
126+ one PR remains after filtering. The script still applies its existing
127+ ` request-ci ` and pending-check deferrals before removing the queue label and
128+ reporting a hard failure.
128129
129130> The personal token needs permission for public repositories and to read
130131> profiles. It is used by ` @node-core/utils ` and by the landing job for
@@ -146,18 +147,18 @@ done here since `git node land` will fail if the last CI failed.
146147The script removes the ` commit-queue ` label, then runs ` git node land ` ,
147148forwarding stdout and stderr to a file. PRs that are only blocked on wait time
148149should have already been filtered by the metadata check. If a hard readiness
149- failure appears between the selector job and ` git node land ` , the landing job
150- adds a ` commit-queue-failed ` label to the PR, leaves a comment with the output
151- of ` git node land ` , and then aborts the landing session. If the abort fails,
152- the queue stops instead of continuing in an unknown state.
153-
154- Fast-tracked PRs use the metadata check before the landing job. If the
155- fast-track request has not yet received enough collaborator thumbs-up, the queue
156- keeps the ` commit-queue ` label and retries until either the fast-track request
157- is approved or the PR becomes landable through the regular wait-time rules. The
158- commit queue does not create the fast-track request comment; that is handled
159- when the ` fast-track ` label is added. If that comment is missing, the queue
160- reports the failure instead of keeping the PR queued.
150+ failure appears between the metadata filter and ` git node land ` , the landing
151+ job adds a ` commit-queue-failed ` label to the PR, leaves a comment with the
152+ output of ` git node land ` , and then aborts the landing session. If the abort
153+ fails, the queue stops instead of continuing in an unknown state.
154+
155+ Fast-tracked PRs use the metadata check before checkout and the landing script.
156+ If the fast-track request has not yet received enough collaborator thumbs-up,
157+ the queue keeps the ` commit-queue ` label and retries until either the
158+ fast-track request is approved or the PR becomes landable through the regular
159+ wait-time rules. The commit queue does not create the fast-track request
160+ comment; that is handled when the ` fast-track ` label is added. If that comment
161+ is missing, the queue reports the failure instead of keeping the PR queued.
161162
162163If no errors happen during ` git node land ` , the script either pushes the direct
163164rebase landing to ` main ` or uses GitHub's squash merge API for single-commit and
0 commit comments