From 7a70bc55dcfb6d557ad19ba2d706cc7e3932c3ee Mon Sep 17 00:00:00 2001 From: John Blackbourn Date: Tue, 23 Nov 2021 17:40:00 +0000 Subject: [PATCH] Build/Test Tools: Lower the timeout for GitHub Actions jobs so runaway or stalled processes don't risk running for the default timeout duration of six hours. See #53363 git-svn-id: https://develop.svn.wordpress.org/trunk@52233 602fd350-edb4-49c9-b593-d223f7449a82 --- .github/workflows/coding-standards.yml | 2 ++ .github/workflows/end-to-end-tests.yml | 1 + .github/workflows/javascript-tests.yml | 1 + .github/workflows/php-compatibility.yml | 1 + .github/workflows/phpunit-tests.yml | 1 + .github/workflows/slack-notifications.yml | 5 +++++ .github/workflows/test-coverage.yml | 1 + .github/workflows/test-npm.yml | 2 ++ .github/workflows/test-old-branches.yml | 1 + .github/workflows/welcome-new-contributors.yml | 1 + 10 files changed, 16 insertions(+) diff --git a/.github/workflows/coding-standards.yml b/.github/workflows/coding-standards.yml index 6f611dd271..770e3512dd 100644 --- a/.github/workflows/coding-standards.yml +++ b/.github/workflows/coding-standards.yml @@ -58,6 +58,7 @@ jobs: phpcs: name: PHP coding standards runs-on: ubuntu-latest + timeout-minutes: 20 if: ${{ github.repository == 'WordPress/wordpress-develop' || github.event_name == 'pull_request' }} steps: @@ -123,6 +124,7 @@ jobs: jshint: name: JavaScript coding standards runs-on: ubuntu-latest + timeout-minutes: 20 if: ${{ github.repository == 'WordPress/wordpress-develop' || github.event_name == 'pull_request' }} env: PUPPETEER_SKIP_CHROMIUM_DOWNLOAD: ${{ true }} diff --git a/.github/workflows/end-to-end-tests.yml b/.github/workflows/end-to-end-tests.yml index 6b6a9abe71..075e94c34e 100644 --- a/.github/workflows/end-to-end-tests.yml +++ b/.github/workflows/end-to-end-tests.yml @@ -47,6 +47,7 @@ jobs: e2e-tests: name: E2E Tests runs-on: ubuntu-latest + timeout-minutes: 20 if: ${{ github.repository == 'WordPress/wordpress-develop' || github.event_name == 'pull_request' }} steps: diff --git a/.github/workflows/javascript-tests.yml b/.github/workflows/javascript-tests.yml index 081bb239a9..df0e5724f8 100644 --- a/.github/workflows/javascript-tests.yml +++ b/.github/workflows/javascript-tests.yml @@ -51,6 +51,7 @@ jobs: test-js: name: QUnit Tests runs-on: ubuntu-latest + timeout-minutes: 20 if: ${{ github.repository == 'WordPress/wordpress-develop' || github.event_name == 'pull_request' }} steps: diff --git a/.github/workflows/php-compatibility.yml b/.github/workflows/php-compatibility.yml index 30afda0910..daf58a458c 100644 --- a/.github/workflows/php-compatibility.yml +++ b/.github/workflows/php-compatibility.yml @@ -52,6 +52,7 @@ jobs: php-compatibility: name: Check PHP compatibility runs-on: ubuntu-latest + timeout-minutes: 20 if: ${{ github.repository == 'WordPress/wordpress-develop' || github.event_name == 'pull_request' }} steps: diff --git a/.github/workflows/phpunit-tests.yml b/.github/workflows/phpunit-tests.yml index 01eeb69712..b5b414874a 100644 --- a/.github/workflows/phpunit-tests.yml +++ b/.github/workflows/phpunit-tests.yml @@ -60,6 +60,7 @@ jobs: test-php: name: ${{ matrix.php }}${{ matrix.multisite && ' multisite' || '' }}${{ matrix.split_slow && ' slow tests' || '' }}${{ matrix.memcached && ' with memcached' || '' }} on ${{ matrix.os }} runs-on: ${{ matrix.os }} + timeout-minutes: 20 if: ${{ github.repository == 'WordPress/wordpress-develop' || github.event_name == 'pull_request' }} strategy: fail-fast: false diff --git a/.github/workflows/slack-notifications.yml b/.github/workflows/slack-notifications.yml index 356624b04a..7a58813648 100644 --- a/.github/workflows/slack-notifications.yml +++ b/.github/workflows/slack-notifications.yml @@ -61,6 +61,7 @@ jobs: prepare: name: Prepare notifications runs-on: ubuntu-latest + timeout-minutes: 5 if: ${{ github.repository == 'WordPress/wordpress-develop' && github.event.workflow_run.event != 'pull_request' }} outputs: previous_conclusion: ${{ steps.previous-conclusion.outputs.previous_conclusion }} @@ -129,6 +130,7 @@ jobs: failure: name: Failure notifications runs-on: ubuntu-latest + timeout-minutes: 5 needs: [ prepare ] if: ${{ github.event_name == 'workflow_run' && github.event.workflow_run.conclusion == 'failure' || inputs.calling_status == 'failure' || failure() }} @@ -144,6 +146,7 @@ jobs: fixed: name: Fixed notifications runs-on: ubuntu-latest + timeout-minutes: 5 needs: [ prepare ] if: ${{ needs.prepare.outputs.previous_conclusion == 'failure' && ( github.event_name == 'workflow_run' && github.event.workflow_run.conclusion == 'success' || inputs.calling_status == 'success' ) && success() }} @@ -159,6 +162,7 @@ jobs: success: name: Success notifications runs-on: ubuntu-latest + timeout-minutes: 5 needs: [ prepare ] if: ${{ github.event_name == 'workflow_run' && github.event.workflow_run.conclusion == 'success' || inputs.calling_status == 'success' && success() }} @@ -174,6 +178,7 @@ jobs: cancelled: name: Cancelled notifications runs-on: ubuntu-latest + timeout-minutes: 5 needs: [ prepare ] if: ${{ github.event_name == 'workflow_run' && github.event.workflow_run.conclusion == 'cancelled' || inputs.calling_status == 'cancelled' || cancelled() }} diff --git a/.github/workflows/test-coverage.yml b/.github/workflows/test-coverage.yml index cd827004b6..caece3306d 100644 --- a/.github/workflows/test-coverage.yml +++ b/.github/workflows/test-coverage.yml @@ -47,6 +47,7 @@ jobs: test-coverage-report: name: ${{ matrix.multisite && 'Multisite' || 'Single site' }} report runs-on: ubuntu-latest + timeout-minutes: 120 if: ${{ github.repository == 'WordPress/wordpress-develop' }} strategy: fail-fast: false diff --git a/.github/workflows/test-npm.yml b/.github/workflows/test-npm.yml index 505657d3f4..05239b4184 100644 --- a/.github/workflows/test-npm.yml +++ b/.github/workflows/test-npm.yml @@ -50,6 +50,7 @@ jobs: test-npm: name: Test NPM on ${{ matrix.os }} runs-on: ${{ matrix.os }} + timeout-minutes: 20 if: ${{ github.repository == 'WordPress/wordpress-develop' || github.event_name == 'pull_request' }} strategy: fail-fast: false @@ -113,6 +114,7 @@ jobs: test-npm-macos: name: Test NPM on MacOS runs-on: macos-latest + timeout-minutes: 20 if: ${{ github.repository == 'WordPress/wordpress-develop' }} steps: - name: Checkout repository diff --git a/.github/workflows/test-old-branches.yml b/.github/workflows/test-old-branches.yml index 743a09e976..0770295d13 100644 --- a/.github/workflows/test-old-branches.yml +++ b/.github/workflows/test-old-branches.yml @@ -16,6 +16,7 @@ jobs: dispatch-workflows-for-old-branches: name: ${{ matrix.workflow }} for ${{ matrix.branch }} runs-on: ubuntu-latest + timeout-minutes: 20 if: ${{ github.repository == 'WordPress/wordpress-develop' }} strategy: fail-fast: false diff --git a/.github/workflows/welcome-new-contributors.yml b/.github/workflows/welcome-new-contributors.yml index f475a432a0..44ddf0b02d 100644 --- a/.github/workflows/welcome-new-contributors.yml +++ b/.github/workflows/welcome-new-contributors.yml @@ -8,6 +8,7 @@ jobs: # Comments on a pull request when the author is a new contributor. post-welcome-message: runs-on: ubuntu-latest + timeout-minutes: 5 if: ${{ github.repository == 'WordPress/wordpress-develop' }} steps: