Make WordPress Core

Opened 14 months ago

Closed 6 months ago

Last modified 4 months ago

#64083 closed task (blessed) (fixed)

Trim the GitHub Actions workflows for older branches (and possibly `trunk`)

Reported by: johnbillion Owned by: johnbillion
Priority: normal Milestone: 7.0
Component: Build/Test Tools Version:
Severity: normal Keywords: has-patch
Cc: Focuses:

Description (last modified by johnbillion)

For older branches (ie. prior to 6.9 currently) I propose:

  1. Unused workflow files (mostly the reusable ones) are trimmed. This has been done previously on an ad-hoc basis, this is just catching up recent branches.
  2. The performance.yml workflow is additionally removed. Realistically this is not something that anybody looks at outside of trunk and the current major, and results for branches aren't available on codevitals.run.
  3. The matrices for PHPUnit tests are reduced to boundary testing of each major PHP version, which means the highest and lowest supported version in each of 5, 7, and 8. This reduces the time for tests to run and reduces the number of minutes consumed by workflows. This is especially useful when preparing backports to multiple branches.

Change History (80)

This ticket was mentioned in ​PR #10165 on ​WordPress/wordpress-develop by ​@johnbillion.


14 months ago
#1

  • Keywords has-patch added

For the 6.7 branch:

  • Deletes unnecessary workflows
  • Trims the unit testing matrix to the highest and lowest supported version of each major PHP branch.

This ticket was mentioned in ​Slack in #core by johnbillion. ​View the logs.


13 months ago

#3 @desrosj
12 months ago

  • Milestone Future Release → 7.0
  • Summary Trim the GitHub Actions workflows for older branches → Trim the GitHub Actions workflows for older branches (and possibly `trunk`)

After the bottleneck that occurred leading up to the 6.9 beta 1 release that resulted in the need for [61018], I am going to move this to the 7.0 milestone.

While [61018] was a great short-term fix, it is not a sustainable way to limit the number of jobs long-term. I've updated the ticket summary to also include trunk.

#4 @desrosj
12 months ago

In 61225:

Build/Test Tools: Revert [61018].

[61018] was a good way to quickly limit the number of jobs spawned by the PHPUnit test workflow during the time leading up to beta releases for the 6.9 release, but this approach is not sustainable. This reverts that commit so a better long term solution can be explored in #64083.

See #63170, #64083.

#5 @peterwilsoncc
12 months ago

In 61256:

Build/Test Tools: Revert [61018].

[61018] was a good way to quickly limit the number of jobs spawned by the PHPUnit test workflow during the time leading up to beta releases for the 6.9 release, but this approach is not sustainable. This reverts that commit so a better long term solution can be explored in #64083.

Reviewed by peterwilsoncc.
Merges [61225] to the 6.9 branch.

See #63170, #64083.

#6 @johnbillion
9 months ago

In 61736:

Build/Test Tools: Trim the 6.7 workflows.

This removes reusable workflows that are no longer referenced in the branch, and trims the unit testing matrix to the highest and lowest supported version of each major PHP branchand database version.

Props desrosj, johnbillion

See #64083

#7 @johnbillion
9 months ago

  • Description modified (diff)

#8 @johnbillion
9 months ago

  • Status assigned → accepted

This ticket was mentioned in ​PR #11043 on ​WordPress/wordpress-develop by ​@johnbillion.


9 months ago
#10

Previously: #10165

This ticket was mentioned in ​PR #11044 on ​WordPress/wordpress-develop by ​@johnbillion.


9 months ago
#11

Previously: #10165

The reusable workflow files have already been removed from this branch.

This ticket was mentioned in ​PR #11045 on ​WordPress/wordpress-develop by ​@johnbillion.


9 months ago
#12

Previously: #10165

The reusable workflow files have already been removed from this branch.

This ticket was mentioned in ​PR #11046 on ​WordPress/wordpress-develop by ​@johnbillion.


9 months ago
#13

Previously: #10165

The reusable workflow files have already been removed from this branch.

This ticket was mentioned in ​PR #11048 on ​WordPress/wordpress-develop by ​@johnbillion.


9 months ago
#14

Previously: #10165

  • The reusable workflow files have already been removed from this branch.
  • This additionally pins the e2e test workflow to PHP 8.2 as they fail on latest (which is 8.3) in this branch.

This ticket was mentioned in ​PR #11060 on ​WordPress/wordpress-develop by ​@johnbillion.


9 months ago
#15

Previously: #10165

  • The reusable workflow files have already been removed from this branch.
  • The e2e test workflow in this branch is already pinned to PHP 8.0.

#16 @johnbillion
9 months ago

In 61801:

Build/Test Tools: Trim the 6.6 workflows.

This removes reusable workflows that are no longer referenced in the branch, and trims the unit testing matrix to the highest and lowest supported version of each major PHP branch and database version.

Props desrosj, johnbillion

See #64083

#17 @johnbillion
9 months ago

In 61802:

Build/Test Tools: Trim the 6.5 workflows.

This removes reusable workflows that are no longer referenced in the branch, and trims the unit testing matrix to the highest and lowest supported version of each major PHP branch and database version.

Props desrosj, johnbillion

See #64083

#18 @johnbillion
9 months ago

In 61803:

Build/Test Tools: Trim the 6.4 workflows.

This removes reusable workflows that are no longer referenced in the branch, and trims the unit testing matrix to the highest and lowest supported version of each major PHP branch and database version.

Props desrosj, johnbillion

See #64083

#22 @johnbillion
9 months ago

In 61804:

Build/Test Tools: Trim the 6.3 workflows.

This removes reusable workflows that are no longer referenced in the branch, and trims the unit testing matrix to the highest and lowest supported version of each major PHP branch and database version.

Props desrosj, johnbillion

See #64083

#24 @johnbillion
9 months ago

In 61805:

Build/Test Tools: Trim the 6.2 workflows.

This removes reusable workflows that are no longer referenced in the branch, and trims the unit testing matrix to the highest and lowest supported version of each major PHP branch and database version.

Props desrosj, johnbillion

See #64083

#26 @johnbillion
9 months ago

In 61806:

Build/Test Tools: Trim the 6.1 workflows.

This removes reusable workflows that are no longer referenced in the branch, and trims the unit testing matrix to the highest and lowest supported version of each major PHP branch and database version.

Props desrosj, johnbillion

See #64083

This ticket was mentioned in ​PR #11134 on ​WordPress/wordpress-develop by ​@johnbillion.


9 months ago
#28

Previously: #10165

  • The reusable workflow files have already been removed from this branch.
  • The e2e test workflow in this branch is already pinned to PHP 8.0.

This ticket was mentioned in ​PR #11136 on ​WordPress/wordpress-develop by ​@johnbillion.


9 months ago
#29

Previously: #10165

  • No workflow files need deleting from this branch.
  • The e2e test workflow in this branch is already pinned to PHP 8.0.

This ticket was mentioned in ​PR #11137 on ​WordPress/wordpress-develop by ​@johnbillion.


9 months ago
#30

Previously: #10165

  • No workflow files need deleting from this branch.
  • The e2e test workflow in this branch is already pinned to PHP 8.0.

This ticket was mentioned in ​PR #11138 on ​WordPress/wordpress-develop by ​@johnbillion.


9 months ago
#31

Previously: #10165

  • No workflow files need deleting from this branch.
  • The e2e workflow doesn't exist in this branch.

This ticket was mentioned in ​PR #11139 on ​WordPress/wordpress-develop by ​@johnbillion.


9 months ago
#32

Previously: #10165

  • No workflow files need deleting from this branch.
  • The e2e workflow doesn't exist in this branch.

This ticket was mentioned in ​PR #11140 on ​WordPress/wordpress-develop by ​@johnbillion.


9 months ago
#33

Previously: #10165

  • No workflow files need deleting from this branch.
  • The e2e workflow doesn't exist in this branch.

This ticket was mentioned in ​PR #11141 on ​WordPress/wordpress-develop by ​@johnbillion.


9 months ago
#34

Previously: #10165

  • No workflow files need deleting from this branch.
  • The e2e workflow doesn't exist in this branch.

This ticket was mentioned in ​PR #11142 on ​WordPress/wordpress-develop by ​@johnbillion.


9 months ago
#35

Previously: #10165

  • No workflow files need deleting from this branch.
  • The e2e workflow doesn't exist in this branch.

This ticket was mentioned in ​PR #11143 on ​WordPress/wordpress-develop by ​@johnbillion.


9 months ago
#36

Previously: #10165

  • No workflow files need deleting from this branch.
  • The e2e workflow doesn't exist in this branch.

This ticket was mentioned in ​PR #11144 on ​WordPress/wordpress-develop by ​@johnbillion.


9 months ago
#37

Previously: #10165

This trims the matrix down to PHP 5.3-5.6 and 7.0-7.3, the difference from later branches is the 5.6 and 7.0 jobs are built from the include directive instead of directly in the martrix due to the older PHPUnit version requirements.

  • No workflow files need deleting from this branch.
  • The e2e workflow doesn't exist in this branch.

This ticket was mentioned in ​PR #11145 on ​WordPress/wordpress-develop by ​@johnbillion.


9 months ago
#38

Previously: #10165

This trims the matrix down to PHP 5.3, 5.6, 7.0, and 7.3. Similarly to the 5.1 branch, the 5.6, 7.0, and 7.3 jobs are built from the include directive instead of directly in the matrix due to the older PHPUnit version requirements.

  • No workflow files need deleting from this branch.
  • The e2e workflow doesn't exist in this branch.

This ticket was mentioned in ​PR #11146 on ​WordPress/wordpress-develop by ​@johnbillion.


9 months ago
#39

Previously: #10165

This trims the matrix down to PHP 5.3, 5.6, 7.0, and 7.2. Similarly to the 5.0 and 5.1 branches, the later jobs are built from the include directive instead of directly in the matrix due to the older PHPUnit version requirements.

  • No workflow files need deleting from this branch.
  • The e2e workflow doesn't exist in this branch.

This ticket was mentioned in ​PR #11147 on ​WordPress/wordpress-develop by ​@johnbillion.


9 months ago
#40

Previously: #10165

This trims the matrix down to PHP 5.3, 5.6, 7.0, and 7.1. The 5.6 jobs are built from the include directive.

  • No workflow files need deleting from this branch.
  • The e2e workflow doesn't exist in this branch.

This ticket was mentioned in ​PR #11148 on ​WordPress/wordpress-develop by ​@johnbillion.


9 months ago
#41

Previously: #10165

This trims the matrix down to PHP 5.3, 5.6, 7.0, and 7.1. The 5.6 and 7.x jobs are built from the include directive.

  • No workflow files need deleting from this branch.
  • The e2e workflow doesn't exist in this branch.

​@desrosj commented on ​PR #11134:


9 months ago
#42

@johnbillion What do you think of also trimming 8.1 here? It's set to allow-failures. The release did have beta support. But if the suite does not fully pass to begin with, is it worth keeping those combinations?

I reviewed this one after th 5.9 PR (#11136). But the same question goes for that branch also.

#43 @johnbillion
9 months ago

In 61810:

Build/Test Tools: Trim the 6.0 workflows.

This removes reusable workflows that are no longer referenced in the branch, and trims the unit testing matrix to the highest and lowest supported version of each major PHP branch and database version.

Props desrosj, johnbillion

See #64083

#44 @johnbillion
9 months ago

In 61811:

Build/Test Tools: Trim the 5.9 workflows.

This trims the unit testing matrix to the highest and lowest supported version of each major PHP branch.

Props desrosj, johnbillion

See #64083

#45 @johnbillion
9 months ago

In 61812:

Build/Test Tools: Trim the 5.8 workflows.

This trims the unit testing matrix to the highest and lowest supported version of each major PHP branch.

Props desrosj, johnbillion

See #64083

#46 @johnbillion
9 months ago

In 61813:

Build/Test Tools: Trim the 5.7 workflows.

This trims the unit testing matrix to the highest and lowest supported version of each major PHP branch.

Props desrosj, johnbillion

See #64083

#47 @johnbillion
9 months ago

In 61814:

Build/Test Tools: Trim the 5.6 workflows.

This trims the unit testing matrix to the highest and lowest supported version of each major PHP branch.

Props desrosj, johnbillion

See #64083

#48 @johnbillion
9 months ago

In 61815:

Build/Test Tools: Trim the 5.5 workflows.

This trims the unit testing matrix to the highest and lowest supported version of each major PHP branch.

Props desrosj, johnbillion

See #64083

#49 @johnbillion
9 months ago

In 61816:

Build/Test Tools: Trim the 5.4 workflows.

This trims the unit testing matrix to the highest and lowest supported version of each major PHP branch.

Props desrosj, johnbillion

See #64083

#50 @johnbillion
9 months ago

In 61817:

Build/Test Tools: Trim the 5.3 workflows.

This trims the unit testing matrix to the highest and lowest supported version of each major PHP branch.

Props desrosj, johnbillion

See #64083

#51 @johnbillion
9 months ago

In 61818:

Build/Test Tools: Trim the 5.2 workflows.

This trims the unit testing matrix to the highest and lowest supported version of each major PHP branch.

Props desrosj, johnbillion

See #64083

#52 @johnbillion
9 months ago

In 61819:

Build/Test Tools: Trim the 5.1 workflows.

This trims the unit testing matrix to the highest and lowest supported version of each major PHP branch.

Props desrosj, johnbillion

See #64083

#53 @johnbillion
9 months ago

In 61820:

Build/Test Tools: Trim the 5.0 workflows.

This trims the unit testing matrix to the highest and lowest supported version of each major PHP branch.

Props desrosj, johnbillion

See #64083

#54 @johnbillion
9 months ago

In 61821:

Build/Test Tools: Trim the 4.9 workflows.

This trims the unit testing matrix to the highest and lowest supported version of each major PHP branch.

Props desrosj, johnbillion

See #64083

#55 @johnbillion
9 months ago

In 61822:

Build/Test Tools: Trim the 4.8 workflows.

This trims the unit testing matrix to the highest and lowest supported version of each major PHP branch.

Props desrosj, johnbillion

See #64083

#56 @johnbillion
9 months ago

  • Resolution → fixed
  • Status accepted → closed

In 61823:

Build/Test Tools: Trim the 4.7 workflows.

This trims the unit testing matrix to the highest and lowest supported version of each major PHP branch.

Props desrosj, johnbillion

Fixes #64083

#61 @desrosj
8 months ago

  • Resolution fixed
  • Status closed → reopened

@johnbillion reopening this because it seems like the commit to the 6.0 branch caused some ​unexpected changes to the built files.

I noticed the 6.0-branch branch as one of two in the Active list by chance looking into whether the branch created in [61863] made it to the WordPress/WordPress mirror on GitHub.

I'm not at all clear what caused this since no changes were made to package.json or package-lock.json, but a good number of JavaScript files and any generated files containing computed hashes of those files were updated. The changes all seem similar to what you'd expect if webpack or a related dependency were updated, and I believe the changes all look OK.

But this will increase the package size for the next 6.0 auto-update should a security patch need to be shipped to this branch.

I'm reopening for now just to look into this a bit more. It would be good to understand what happened.

#62 @johnbillion
8 months ago

Jon and I looked through the branches that were changed last week (4.7 - 6.9). The only affected branch is 6.0. I'll speak with the systems team to find out what changed on the build server since ​the last commit in the 6.0 branch in November.

#64 @johnbillion
8 months ago

CC @isabel_brison, @peterwilsoncc, @sergeybiryukov, @davidbaumwald, see the comments above. I was just pointed to [57982] by @jorbin. Do you have any idea why the built files in the 6.0 branch might have changed?

#65 @johnbillion
8 months ago

Another observation: The unexpected change to built files on a branch is completely invisible without manually checking every commit. This seems like a major blind spot, not only for unintentional errors like the above but also as a supply chain security concern.

#66 @desrosj
8 months ago

In 62035:

Build/Test Tools: Trim performance workflow from 6.7-6.4.

[61736], [61801], [61082], and [61083] removed the performance.yml workflow from the 6.7-6.4 branches as part of #64083.

The workflow also needs to be removed from the workflow responsible for testing old branches to avoid failures when attempting to trigger a workflow_dispatch event on a non-existent workflow file.

See #64227, #64083.

#67 @desrosj
8 months ago

#64297 was marked as a duplicate.

#68 @johnbillion
8 months ago

In 62181:

Build/Test Tools: Revert [61810] while we investigate issues with the build process for the 6.0 branch.

See #64083

#69 @johnbillion
8 months ago

In 62183:

Build/Test Tools: Trim the 6.0 workflows.

This is a re-commit of [61810] which was reverted in [62181].

See #64083

#70 @desrosj
7 months ago

@johnbillion I believe that this can be closed out now. Am I missing anything that has not been completed?

#71 @johnbillion
6 months ago

  • Resolution → fixed
  • Status reopened → closed

#72 @johnbillion
4 months ago

In 62856:

Build/Test Tools: Trim the PHPUnit matrix to boundary PHP versions in the 7.0 branch.

This reduces the number of jobs that get triggered for each push or PR to the branch while retaining testing on the highest and lowest supported versions of PHP.

Developed in ​https://github.com/WordPress/wordpress-develop/pull/12720

Props lancewillett, adrianmoldovanwp

See #65736, #64083

#73 @lancewillett
4 months ago

In 62858:

Build/Test Tools: Trim the PHPUnit matrix to boundary PHP versions.

Test only the highest and lowest supported PHP version of each major (7.4, 8.0, 8.5) on push and pull request events; the weekly scheduled run still exercises every supported version.

Version-specific failures cluster at the boundaries of each major, so the intermediate minors add job count without adding coverage. Cuts base PHPUnit combinations from roughly 168 to 72 per CI run for both time and cost savings, and a much better developer experience in core GitHub repos.

Developed in: ​https://github.com/WordPress/wordpress-develop/pull/12719

Props johnbillion, adrianmoldovanwp
Fixes #65736, see #64083

This ticket was mentioned in ​PR #12726 on ​WordPress/wordpress-develop by ​@lancewillett.


4 months ago
#74

The 6.8 PHPUnit matrix runs the full PHP axis (7.2–8.4) across three job groups (about 198 matrix jobs), while trunk (#12719) and 7.0 (#12720) were trimmed to boundary versions. During a security release several branches run at once, and their summed matrices approach the GitHub Actions concurrency ceiling. 6.8's full matrix is the single largest contributor.

This trims the PHP axis to the highest and lowest of each major (7.2, 7.4, 8.0, 8.4), matching trunk and 7.0, and drops 6.8 from ~198 to ~99 jobs. The intermediate versions still run on trunk and the weekly scheduled full matrix, so coverage holds.

Follows the boundary-trim approach from #64083, extended to the current branches in #65736.

Verified with actionlint locally (it also flagged a now-orphaned exclude entry for PHP 7.3, removed here).

#75 @lancewillett
4 months ago

In 62863:

Build/Test Tools: Trim the PHPUnit matrix to boundary PHP versions in the 6.8 branch.

The 6.8 PHPUnit matrix runs the full PHP axis (7.2 through 8.4) across three job groups, about 198 matrix jobs, while trunk and 7.0 were trimmed to boundary versions. During a security release several branches run at once, and 6.8's full matrix is the single largest contributor to the concurrent-job peak. Trim the PHP axis to the highest and lowest of each major (7.2, 7.4, 8.0, 8.4), matching trunk and 7.0. The intermediate versions still run on trunk and the weekly scheduled full matrix, so coverage holds.

Developed in: ​https://github.com/WordPress/wordpress-develop/pull/12726

See #65736, see #64083

#78 @johnbillion
4 months ago

In 62945:

Build/Test Tools: Trim the PHPUnit matrix to boundary PHP versions in the 6.9 branch.

Developed in ​https://github.com/WordPress/wordpress-develop/pull/12776

See #65736, #64083

​@adrianmoldovanwp commented on ​PR #12726:


4 months ago
#79

Looks like the change already landed in 6.8. The PR has 0 changes.

Note: See TracTickets for help on using tickets.