Make WordPress Core


Ignore:
Timestamp:
08/01/2025 12:42:18 PM (8 months ago)
Author:
desrosj
Message:

Build/Test Tools: Spawn fewer jobs in GitHub Actions on forks.

The GitHub Actions workflows currently limit when jobs run for forks by short-circuiting any that are triggered by push events when not running within the wordpress-develop repository.

Because the large majority of forks are not created under organizations, they will be subject to the individual account limit of 20 concurrent jobs (40 for pro accounts) at any given time instead of the 500 concurrent job limit that applies to the WordPress organization. This means that a single pull request back to a fork can take several hours to complete the workflow jobs that are spawned.

This revises the conditional statements to further limit the number of jobs that spawn within a fork while still allowing the full test matrices for forks within the WordPress organization and pull requests back to wordpress-develop.

These adjustments result in a maximum of 53 jobs when all workflows configured to run within forks are triggered. Of these, ~66% will run in less than 3 minutes, and ~55% will run in less than 1 minute.

Props jorbin, johnbillion.
Fixes #63752.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/.github/workflows/upgrade-testing.yml

    r60532 r60534  
    5959    name: ${{ matrix.wp }} to ${{ inputs.new-version && inputs.new-version || 'latest' }}
    6060    uses: ./.github/workflows/reusable-upgrade-testing.yml
    61     if: ${{ github.repository == 'WordPress/wordpress-develop' || ( github.event_name == 'pull_request' && github.actor != 'dependabot[bot]' ) }}
     61    if: ${{ github.repository == 'WordPress/wordpress-develop' }}
    6262    strategy:
    6363      fail-fast: false
     
    9494    name: ${{ matrix.wp }} to ${{ inputs.new-version && inputs.new-version || 'latest' }}
    9595    uses: ./.github/workflows/reusable-upgrade-testing.yml
    96     if: ${{ github.repository == 'WordPress/wordpress-develop' || ( github.event_name == 'pull_request' && github.actor != 'dependabot[bot]' ) }}
     96    if: ${{ github.repository == 'WordPress/wordpress-develop' }}
    9797    strategy:
    9898      fail-fast: false
     
    122122    name: ${{ matrix.wp }} to ${{ inputs.new-version && inputs.new-version || 'latest' }}
    123123    uses: ./.github/workflows/reusable-upgrade-testing.yml
    124     if: ${{ github.repository == 'WordPress/wordpress-develop' || ( github.event_name == 'pull_request' && github.actor != 'dependabot[bot]' ) }}
     124    if: ${{ github.repository == 'WordPress/wordpress-develop' }}
    125125    strategy:
    126126      fail-fast: false
     
    154154    name: ${{ matrix.wp }} to ${{ inputs.new-version && inputs.new-version || 'latest' }}
    155155    uses: ./.github/workflows/reusable-upgrade-testing.yml
    156     if: ${{ github.repository == 'WordPress/wordpress-develop' || ( github.event_name == 'pull_request' && github.actor != 'dependabot[bot]' ) }}
     156    if: ${{ github.repository == 'WordPress/wordpress-develop' }}
    157157    strategy:
    158158      fail-fast: false
     
    182182    name: ${{ matrix.wp }} to ${{ inputs.new-version && inputs.new-version || 'latest' }}
    183183    uses: ./.github/workflows/reusable-upgrade-testing.yml
    184     if: ${{ github.repository == 'WordPress/wordpress-develop' || ( github.event_name == 'pull_request' && github.actor != 'dependabot[bot]' ) }}
     184    if: ${{ github.repository == 'WordPress/wordpress-develop' }}
    185185    strategy:
    186186      fail-fast: false
Note: See TracChangeset for help on using the changeset viewer.