Skip to content

Repair wp/6.7 branch Actions: Remove SimenB/github-actions-cpu-cores dependency - #214

Closed
desrosj wants to merge 2 commits into
fix-actions-6.7/fix-flaky-metabox-tinymce-racefrom
fix-actions-6.7/remove-cpu-cores-dependency
Closed

desrosj wants to merge 2 commits into
fix-actions-6.7/fix-flaky-metabox-tinymce-racefrom
fix-actions-6.7/remove-cpu-cores-dependency

Conversation

@desrosj

@desrosj desrosj commented Sep 11, 2026 •

Copy link
Copy Markdown
Owner

What?

Removes the SimenB/github-actions-cpu-cores dependency from every job that uses it in .github/workflows/unit-test.yml — the unit-js, unit-js-date, and mobile-unit-js jobs each used this third-party action (via a cpu-cores step output) to determine --maxWorkers for their Jest runs. This is now the sole place in the stack that removes this dependency, and it removes every remaining reference in the repository.

Why?

Trunk removed this dependency in commit 4d02abd34c61e8bcf30399c219fdccedaf0e8a84 ("Remove dependency used for counting available CPUs", WordPress/gutenberg#78593), switching from a third-party action to a direct nproc call to report the runner's available CPU count. That commit only touched the JS unit test and date test jobs — it didn't touch mobile-unit-js (which trunk later removed entirely, months afterward, in a separate, unrelated change), so this branch's copy of that job was left behind with a remaining use of the action.

This PR applies the same fix everywhere on this branch: removes each "Determine the number of CPU cores" step and its id: cpu-cores, and changes each --maxWorkers=${{ steps.cpu-cores.outputs.count }} reference to --maxWorkers="$(nproc)", matching the pattern already used elsewhere in unit-test.yml. This fully removes the SimenB/github-actions-cpu-cores dependency from the repository.

Use of AI Tools

This PR was created by Claude Code under my supervision. All code should be treated as AI-produced and not yet reviewed by a human until this PR is marked Ready for Review.

@desrosj
desrosj force-pushed the fix-actions-6.7/remove-cpu-cores-dependency branch from df250bb to 553bde6 Compare September 11, 2026 02:20
@desrosj
desrosj added this pull request to stack #185 September 11, 2026 03:12
@desrosj
desrosj force-pushed the fix-actions-6.7/remove-cpu-cores-dependency branch from 553bde6 to 7088f4a Compare September 11, 2026 16:10
@desrosj
desrosj force-pushed the fix-actions-6.7/remove-cpu-cores-dependency branch from 7088f4a to f99b859 Compare September 14, 2026 01:50
@desrosj
desrosj force-pushed the fix-actions-6.7/remove-cpu-cores-dependency branch from f99b859 to 29c0f28 Compare September 14, 2026 17:38
Removes the `SimenB/github-actions-cpu-cores` step from the `unit-js`
and `unit-js-date` jobs, replacing `--maxWorkers` references to its
output with `$(nproc)`, which reports the same value using a tool
already available on the runner.

Ports WordPress#78593, which removed the same dependency from
these two jobs on trunk. The `mobile-unit-js` job's own use of this
action is left untouched here; it wasn't part of the ported change,
which only touched the JavaScript unit test jobs.
The `mobile-unit-js` job in `unit-test.yml` still used the
`SimenB/github-actions-cpu-cores` action to determine `--maxWorkers`
for its Jest run, via a `cpu-cores` step output. Trunk removed this
dependency in commit `4d02abd34c61e8bcf30399c219fdccedaf0e8a84`
("Remove dependency used for counting available CPUs (WordPress#78593)"),
switching the JS unit test and date test jobs to call `nproc`
directly instead of relying on a third-party action to report the
runner's CPU count. That commit didn't touch the `mobile-unit-js`
job (removed on trunk separately, months later), so this branch's
copy of the job was left with the last remaining reference to the
action in `.github/workflows/unit-test.yml`.

This applies the same fix to that job: remove the "Determine the
number of CPU cores" step and its `id: cpu-cores`, and change
`--maxWorkers=${{ steps.cpu-cores.outputs.count }}` to
`--maxWorkers="$(nproc)"`, matching the pattern already used
elsewhere in this file. This fully removes the
`SimenB/github-actions-cpu-cores` dependency from the repository.
@desrosj
desrosj force-pushed the fix-actions-6.7/remove-cpu-cores-dependency branch from 29c0f28 to d96fa49 Compare September 14, 2026 19:26
@desrosj
desrosj marked this pull request as ready for review September 14, 2026 19:30
@desrosj
desrosj marked this pull request as draft September 14, 2026 19:31
@desrosj
desrosj marked this pull request as ready for review September 14, 2026 19:38
@github-actions

Copy link
Copy Markdown

The following accounts have interacted with this PR and/or linked issues. I will continue to update these lists as activity occurs. You can also manually ask me to refresh this list by adding the props-bot label.

If you're merging code through a pull request on GitHub, copy and paste the following into the bottom of the merge commit message.

Co-authored-by: desrosj <desrosj@git.wordpress.org>

To understand the WordPress project's expectations around crediting contributors, please review the Contributor Attribution page in the Core Handbook.

@desrosj

desrosj commented Sep 15, 2026

Copy link
Copy Markdown
Owner Author

Migrated to real upstream: WordPress#82906. Closing this fork PR.

@desrosj desrosj closed this Sep 15, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant