Skip to content

Add timeouts to all GitHub jobs #2227

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 2 commits into from
Feb 20, 2025
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 2 additions & 0 deletions .github/workflows/contributed-recipes.yml
Original file line number Diff line number Diff line change
Expand Up @@ -29,6 +29,7 @@ on:
jobs:
generate-matrix:
runs-on: ubuntu-24.04
timeout-minutes: 1
outputs:
matrix: ${{ steps.set-matrix.outputs.matrix }}
steps:
Expand All @@ -43,6 +44,7 @@ jobs:

test-recipes:
runs-on: ${{ matrix.runs-on }}
timeout-minutes: 5
needs: generate-matrix
if: github.repository_owner == 'jupyter' || github.repository_owner == 'mathbunnyru'

Expand Down
5 changes: 5 additions & 0 deletions .github/workflows/docker-build-test-upload.yml
Original file line number Diff line number Diff line change
Expand Up @@ -33,10 +33,15 @@ on:
description: GitHub Actions Runner image
required: true
type: string
timeout-minutes:
description: Timeout in minutes
required: true
type: number

jobs:
build-test-upload:
runs-on: ${{ inputs.runs-on }}
timeout-minutes: ${{ inputs.timeout-minutes }}

steps:
- name: Checkout Repo ⚡️
Expand Down
5 changes: 5 additions & 0 deletions .github/workflows/docker-merge-tags.yml
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,10 @@ on:
description: Image name
required: true
type: string
timeout-minutes:
description: Timeout in minutes
type: number
default: 25
Comment on lines +18 to +21
Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This could probably be better set as a param for each image, but for now let's keep one common timeout (the same goes for docker-tag-push.yml)

secrets:
REGISTRY_USERNAME:
required: true
Expand All @@ -24,6 +28,7 @@ on:
jobs:
merge-tags:
runs-on: ubuntu-24.04
timeout-minutes: ${{ inputs.timeout-minutes }}

steps:
- name: Checkout Repo ⚡️
Expand Down
5 changes: 5 additions & 0 deletions .github/workflows/docker-tag-push.yml
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,10 @@ on:
description: Variant tag prefix
required: true
type: string
timeout-minutes:
description: Timeout in minutes
default: 25
type: number
secrets:
REGISTRY_USERNAME:
required: true
Expand All @@ -29,6 +33,7 @@ on:
jobs:
tag-push:
runs-on: ubuntu-24.04
timeout-minutes: ${{ inputs.timeout-minutes }}

steps:
- name: Checkout Repo ⚡️
Expand Down
1 change: 1 addition & 0 deletions .github/workflows/docker-wiki-update.yml
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,7 @@ on:
jobs:
wiki-update:
runs-on: ubuntu-24.04
timeout-minutes: 1

steps:
- name: Checkout Repo ⚡️
Expand Down
27 changes: 27 additions & 0 deletions .github/workflows/docker.yml
Original file line number Diff line number Diff line change
Expand Up @@ -67,6 +67,7 @@ jobs:
image: docker-stacks-foundation
platform: aarch64
runs-on: ubuntu-24.04-arm
timeout-minutes: 10

x86_64-foundation:
uses: ./.github/workflows/docker-build-test-upload.yml
Expand All @@ -75,6 +76,7 @@ jobs:
image: docker-stacks-foundation
platform: x86_64
runs-on: ubuntu-24.04
timeout-minutes: 10

aarch64-base:
uses: ./.github/workflows/docker-build-test-upload.yml
Expand All @@ -83,6 +85,7 @@ jobs:
image: base-notebook
platform: aarch64
runs-on: ubuntu-24.04-arm
timeout-minutes: 15
needs: [aarch64-foundation]

x86_64-base:
Expand All @@ -92,6 +95,7 @@ jobs:
image: base-notebook
platform: x86_64
runs-on: ubuntu-24.04
timeout-minutes: 15
needs: [x86_64-foundation]

aarch64-minimal:
Expand All @@ -101,6 +105,7 @@ jobs:
image: minimal-notebook
platform: aarch64
runs-on: ubuntu-24.04-arm
timeout-minutes: 15
needs: [aarch64-base]
if: ${{ !contains(github.event.pull_request.title, '[FAST_BUILD]') }}

Expand All @@ -111,6 +116,7 @@ jobs:
image: minimal-notebook
platform: x86_64
runs-on: ubuntu-24.04
timeout-minutes: 15
needs: [x86_64-base]
if: ${{ !contains(github.event.pull_request.title, '[FAST_BUILD]') }}

Expand All @@ -121,6 +127,7 @@ jobs:
image: scipy-notebook
platform: aarch64
runs-on: ubuntu-24.04-arm
timeout-minutes: 15
needs: [aarch64-minimal]
if: ${{ !contains(github.event.pull_request.title, '[FAST_BUILD]') }}

Expand All @@ -131,6 +138,7 @@ jobs:
image: scipy-notebook
platform: x86_64
runs-on: ubuntu-24.04
timeout-minutes: 15
needs: [x86_64-minimal]
if: ${{ !contains(github.event.pull_request.title, '[FAST_BUILD]') }}

Expand All @@ -141,6 +149,7 @@ jobs:
image: r-notebook
platform: aarch64
runs-on: ubuntu-24.04-arm
timeout-minutes: 15
needs: [aarch64-minimal]
if: ${{ !contains(github.event.pull_request.title, '[FAST_BUILD]') }}

Expand All @@ -151,6 +160,7 @@ jobs:
image: r-notebook
platform: x86_64
runs-on: ubuntu-24.04
timeout-minutes: 15
needs: [x86_64-minimal]
if: ${{ !contains(github.event.pull_request.title, '[FAST_BUILD]') }}

Expand All @@ -161,6 +171,8 @@ jobs:
image: julia-notebook
platform: aarch64
runs-on: ubuntu-24.04-arm
# This workflow sometimes takes quite long to build
timeout-minutes: 30
needs: [aarch64-minimal]
if: ${{ !contains(github.event.pull_request.title, '[FAST_BUILD]') }}

Expand All @@ -171,6 +183,7 @@ jobs:
image: julia-notebook
platform: x86_64
runs-on: ubuntu-24.04
timeout-minutes: 20
needs: [x86_64-minimal]
if: ${{ !contains(github.event.pull_request.title, '[FAST_BUILD]') }}

Expand All @@ -181,6 +194,7 @@ jobs:
image: tensorflow-notebook
platform: aarch64
runs-on: ubuntu-24.04-arm
timeout-minutes: 15
needs: [aarch64-scipy]
if: ${{ !contains(github.event.pull_request.title, '[FAST_BUILD]') }}

Expand All @@ -191,6 +205,7 @@ jobs:
image: tensorflow-notebook
platform: x86_64
runs-on: ubuntu-24.04
timeout-minutes: 15
needs: [x86_64-scipy]
if: ${{ !contains(github.event.pull_request.title, '[FAST_BUILD]') }}

Expand All @@ -202,6 +217,7 @@ jobs:
variant: cuda
platform: x86_64
runs-on: ubuntu-24.04
timeout-minutes: 20
needs: [x86_64-scipy]
if: ${{ !contains(github.event.pull_request.title, '[FAST_BUILD]') }}

Expand All @@ -212,6 +228,7 @@ jobs:
image: pytorch-notebook
platform: aarch64
runs-on: ubuntu-24.04-arm
timeout-minutes: 20
needs: [aarch64-scipy]
if: ${{ !contains(github.event.pull_request.title, '[FAST_BUILD]') }}

Expand All @@ -222,6 +239,7 @@ jobs:
image: pytorch-notebook
platform: x86_64
runs-on: ubuntu-24.04
timeout-minutes: 20
needs: [x86_64-scipy]
if: ${{ !contains(github.event.pull_request.title, '[FAST_BUILD]') }}

Expand All @@ -233,6 +251,7 @@ jobs:
variant: cuda11
platform: x86_64
runs-on: ubuntu-24.04
timeout-minutes: 20
needs: [x86_64-scipy]
if: ${{ !contains(github.event.pull_request.title, '[FAST_BUILD]') }}

Expand All @@ -244,6 +263,7 @@ jobs:
variant: cuda12
platform: x86_64
runs-on: ubuntu-24.04
timeout-minutes: 20
needs: [x86_64-scipy]
if: ${{ !contains(github.event.pull_request.title, '[FAST_BUILD]') }}

Expand All @@ -254,6 +274,8 @@ jobs:
image: datascience-notebook
platform: aarch64
runs-on: ubuntu-24.04-arm
# This workflow sometimes takes quite long to build
timeout-minutes: 30
needs: [aarch64-scipy]
if: ${{ !contains(github.event.pull_request.title, '[FAST_BUILD]') }}

Expand All @@ -264,6 +286,7 @@ jobs:
image: datascience-notebook
platform: x86_64
runs-on: ubuntu-24.04
timeout-minutes: 25
needs: [x86_64-scipy]
if: ${{ !contains(github.event.pull_request.title, '[FAST_BUILD]') }}

Expand All @@ -274,6 +297,7 @@ jobs:
image: pyspark-notebook
platform: aarch64
runs-on: ubuntu-24.04-arm
timeout-minutes: 20
needs: [aarch64-scipy]
if: ${{ !contains(github.event.pull_request.title, '[FAST_BUILD]') }}

Expand All @@ -284,6 +308,7 @@ jobs:
image: pyspark-notebook
platform: x86_64
runs-on: ubuntu-24.04
timeout-minutes: 15
needs: [x86_64-scipy]
if: ${{ !contains(github.event.pull_request.title, '[FAST_BUILD]') }}

Expand All @@ -294,6 +319,7 @@ jobs:
image: all-spark-notebook
platform: aarch64
runs-on: ubuntu-24.04-arm
timeout-minutes: 20
needs: [aarch64-pyspark]
if: ${{ !contains(github.event.pull_request.title, '[FAST_BUILD]') }}

Expand All @@ -304,6 +330,7 @@ jobs:
image: all-spark-notebook
platform: x86_64
runs-on: ubuntu-24.04
timeout-minutes: 15
needs: [x86_64-pyspark]
if: ${{ !contains(github.event.pull_request.title, '[FAST_BUILD]') }}

Expand Down
1 change: 1 addition & 0 deletions .github/workflows/pre-commit.yml
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,7 @@ permissions:
jobs:
run-hooks:
runs-on: ubuntu-24.04
timeout-minutes: 5

steps:
- name: Checkout Repo ⚡️
Expand Down
1 change: 1 addition & 0 deletions .github/workflows/registry-move.yml
Original file line number Diff line number Diff line change
Expand Up @@ -19,6 +19,7 @@ jobs:
update-overview:
# To be able to use the latest skopeo
runs-on: macos-latest
timeout-minutes: 5
if: github.repository_owner == 'jupyter' || github.repository_owner == 'mathbunnyru'

steps:
Expand Down
1 change: 1 addition & 0 deletions .github/workflows/registry-overviews.yml
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,7 @@ on:
jobs:
update-overview:
runs-on: ubuntu-24.04
timeout-minutes: 1
if: github.repository_owner == 'jupyter' || github.repository_owner == 'mathbunnyru'

steps:
Expand Down
5 changes: 3 additions & 2 deletions .github/workflows/sphinx.yml
Original file line number Diff line number Diff line change
Expand Up @@ -24,10 +24,11 @@ on:

jobs:
build-docs:
runs-on: ubuntu-24.04
timeout-minutes: 5
if: github.repository_owner == 'jupyter' || github.repository_owner == 'mathbunnyru' || github.event_name != 'schedule'
permissions:
contents: write
if: github.repository_owner == 'jupyter' || github.repository_owner == 'mathbunnyru' || github.event_name != 'schedule'
runs-on: ubuntu-24.04

steps:
- name: Checkout Repo ⚡️
Expand Down