From 7182613fb62cf7a4014d2e9938a54350f0d0fae8 Mon Sep 17 00:00:00 2001 From: Naser Mahfouz Date: Tue, 15 Oct 2024 12:18:59 -0400 Subject: [PATCH 1/4] upgrades and fixes to workflows --- .github/workflows/e3sm-gh-ci-cime-tests.yml | 8 ++++++-- .github/workflows/e3sm-gh-ci-w-cime-tests.yml | 8 ++++++-- .github/workflows/e3sm-gh-md-linter.yml | 5 +++++ .github/workflows/e3sm-gh-pages.yml | 2 +- .github/workflows/e3sm-gh-tools-mkatmsrffile-test.yml | 5 +++++ .github/workflows/eamxx-gh-ci-standalone.yml | 1 + .github/workflows/eamxx-gh-pages.yml | 2 +- .github/workflows/eamxx_default_files.yml | 6 +++++- 8 files changed, 30 insertions(+), 7 deletions(-) diff --git a/.github/workflows/e3sm-gh-ci-cime-tests.yml b/.github/workflows/e3sm-gh-ci-cime-tests.yml index 6c9ee1ab114c..5c6ff081f730 100644 --- a/.github/workflows/e3sm-gh-ci-cime-tests.yml +++ b/.github/workflows/e3sm-gh-ci-cime-tests.yml @@ -22,10 +22,14 @@ on: workflow_dispatch: +concurrency: + group: ${{ github.workflow }}-${{ github.event_name }}-${{ github.event.pull_request.number || github.run_id }} + cancel-in-progress: true + jobs: ci: - if: ${{ github.event.repository.name == 'e3sm' }} + if: ${{ github.repository == 'E3SM-Project/E3SM' }} runs-on: ubuntu-latest strategy: fail-fast: false @@ -36,7 +40,7 @@ jobs: - SMS_D_Ln5_P4.ne4pg2_oQU480.F2010-SCREAMv1-MPASSI.ghci-oci_gnu - ERS_Ld5_P4.ne4pg2_oQU480.F2010-SCREAMv1-MPASSI.ghci-oci_gnu.eamxx-prod container: - image: ghcr.io/e3sm-project/containers-ghci:ghci-0.1.0 + image: ghcr.io/e3sm-project/containers-ghci:ghci-0.2.0 steps: - diff --git a/.github/workflows/e3sm-gh-ci-w-cime-tests.yml b/.github/workflows/e3sm-gh-ci-w-cime-tests.yml index 48c367c8f625..d5687a32b375 100644 --- a/.github/workflows/e3sm-gh-ci-w-cime-tests.yml +++ b/.github/workflows/e3sm-gh-ci-w-cime-tests.yml @@ -11,10 +11,14 @@ on: workflow_dispatch: +concurrency: + group: ${{ github.workflow }}-${{ github.event_name }}-${{ github.event.pull_request.number || github.run_id }} + cancel-in-progress: true + jobs: ci-w: - if: ${{ github.event.repository.name == 'e3sm' }} + if: ${{ github.repository == 'E3SM-Project/E3SM' }} runs-on: ubuntu-latest strategy: fail-fast: false @@ -23,7 +27,7 @@ jobs: - SMS_D_Ld1_P8.ne4pg2_oQU480.WCYCL2010NS.ghci-oci_gnu - ERS_Ld3_P8.ne4pg2_oQU480.WCYCL2010NS.ghci-oci_gnu.allactive-wcprod_1850 container: - image: ghcr.io/e3sm-project/containers-ghci:ghci-0.1.0 + image: ghcr.io/e3sm-project/containers-ghci:ghci-0.2.0 steps: - diff --git a/.github/workflows/e3sm-gh-md-linter.yml b/.github/workflows/e3sm-gh-md-linter.yml index 424a871637b6..46319b08658b 100644 --- a/.github/workflows/e3sm-gh-md-linter.yml +++ b/.github/workflows/e3sm-gh-md-linter.yml @@ -10,8 +10,13 @@ on: # for now let's not lint files in eamxx - '!components/eamxx/**/*.md' +concurrency: + group: ${{ github.workflow }}-${{ github.event_name }}-${{ github.event.pull_request.number || github.run_id }} + cancel-in-progress: true + jobs: linter: + if: ${{ github.repository == 'E3SM-Project/E3SM' }} runs-on: ubuntu-latest steps: - uses: actions/checkout@v4 diff --git a/.github/workflows/e3sm-gh-pages.yml b/.github/workflows/e3sm-gh-pages.yml index ebd2ac9c1e97..dec9bc696bfb 100644 --- a/.github/workflows/e3sm-gh-pages.yml +++ b/.github/workflows/e3sm-gh-pages.yml @@ -15,7 +15,7 @@ concurrency: jobs: Build-and-Deploy-docs: - if: ${{ github.event.repository.name == 'e3sm' }} + if: ${{ github.repository == 'E3SM-Project/E3SM' }} runs-on: ubuntu-latest steps: - uses: actions/checkout@v4 diff --git a/.github/workflows/e3sm-gh-tools-mkatmsrffile-test.yml b/.github/workflows/e3sm-gh-tools-mkatmsrffile-test.yml index 8fe212886d9f..fcbf439f4097 100644 --- a/.github/workflows/e3sm-gh-tools-mkatmsrffile-test.yml +++ b/.github/workflows/e3sm-gh-tools-mkatmsrffile-test.yml @@ -11,8 +11,13 @@ on: - cron: '00 15 * * 2' workflow_dispatch: +concurrency: + group: ${{ github.workflow }}-${{ github.event_name }}-${{ github.event.pull_request.number || github.run_id }} + cancel-in-progress: true + jobs: mkatmsrffile-test: + if: ${{ github.repository == 'E3SM-Project/E3SM' }} runs-on: ubuntu-latest defaults: run: diff --git a/.github/workflows/eamxx-gh-ci-standalone.yml b/.github/workflows/eamxx-gh-ci-standalone.yml index d276d600357e..17f79c09eeb4 100644 --- a/.github/workflows/eamxx-gh-ci-standalone.yml +++ b/.github/workflows/eamxx-gh-ci-standalone.yml @@ -18,6 +18,7 @@ on: jobs: ci: + if: ${{ github.repository == 'E3SM-Project/E3SM' }} runs-on: ubuntu-latest strategy: fail-fast: false diff --git a/.github/workflows/eamxx-gh-pages.yml b/.github/workflows/eamxx-gh-pages.yml index 2ce70d97843c..488c2b11a020 100644 --- a/.github/workflows/eamxx-gh-pages.yml +++ b/.github/workflows/eamxx-gh-pages.yml @@ -34,7 +34,7 @@ concurrency: jobs: eamxx-docs: - if: ${{ github.event.repository.name == 'scream' }} + if: ${{ github.repository == 'E3SM-Project/scream' }} runs-on: ubuntu-latest steps: diff --git a/.github/workflows/eamxx_default_files.yml b/.github/workflows/eamxx_default_files.yml index 852bceec5359..38c528306c40 100644 --- a/.github/workflows/eamxx_default_files.yml +++ b/.github/workflows/eamxx_default_files.yml @@ -11,9 +11,13 @@ on: - cron: '00 00 * * *' workflow_dispatch: +concurrency: + group: ${{ github.workflow }}-${{ github.event_name }}-${{ github.event.pull_request.number || github.run_id }} + cancel-in-progress: true + jobs: scream-defaults: - if: ${{ github.event.repository.name == 'e3sm' }} + if: ${{ github.repository == 'E3SM-Project/E3SM' }} runs-on: ubuntu-latest outputs: event_name: ${{ github.event_name }} From c79b9e4a46910b4e1b7719a7253607ed59787016 Mon Sep 17 00:00:00 2001 From: Naser Mahfouz Date: Tue, 15 Oct 2024 12:25:32 -0400 Subject: [PATCH 2/4] updates to miniforge settings --- .github/workflows/e3sm-gh-tools-mkatmsrffile-test.yml | 5 +---- 1 file changed, 1 insertion(+), 4 deletions(-) diff --git a/.github/workflows/e3sm-gh-tools-mkatmsrffile-test.yml b/.github/workflows/e3sm-gh-tools-mkatmsrffile-test.yml index fcbf439f4097..cacb951b8a83 100644 --- a/.github/workflows/e3sm-gh-tools-mkatmsrffile-test.yml +++ b/.github/workflows/e3sm-gh-tools-mkatmsrffile-test.yml @@ -36,10 +36,7 @@ jobs: uses: conda-incubator/setup-miniconda@v3 with: activate-environment: "envmkatmsrffile" - miniforge-variant: Mambaforge miniforge-version: latest - use-mamba: true - mamba-version: "*" channel-priority: strict auto-update-conda: true python-version: 3.11 @@ -47,7 +44,7 @@ jobs: name: Install dependencies run: | echo $CONDA_PREFIX - mamba install -y nco xarray numba numpy netcdf4 + conda install -y nco xarray numba numpy netcdf4 -c conda-forge - name: Run tests working-directory: components/eam/tools/mkatmsrffile From 2dc3601547da390460ef0b408e79a45989dbc8bc Mon Sep 17 00:00:00 2001 From: Naser Mahfouz Date: Tue, 15 Oct 2024 12:26:53 -0400 Subject: [PATCH 3/4] add concurrency check for standalone --- .github/workflows/eamxx-gh-ci-standalone.yml | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/.github/workflows/eamxx-gh-ci-standalone.yml b/.github/workflows/eamxx-gh-ci-standalone.yml index 17f79c09eeb4..19a2ec9cd8e9 100644 --- a/.github/workflows/eamxx-gh-ci-standalone.yml +++ b/.github/workflows/eamxx-gh-ci-standalone.yml @@ -15,6 +15,10 @@ on: workflow_dispatch: +concurrency: + group: ${{ github.workflow }}-${{ github.event_name }}-${{ github.event.pull_request.number || github.run_id }} + cancel-in-progress: true + jobs: ci: From aef19a4edb4332465ccf531a044df991222783ad Mon Sep 17 00:00:00 2001 From: Naser Mahfouz Date: Tue, 15 Oct 2024 12:48:46 -0400 Subject: [PATCH 4/4] rename gh/ci-w to gh-w/ci --- .github/workflows/e3sm-gh-ci-w-cime-tests.yml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/.github/workflows/e3sm-gh-ci-w-cime-tests.yml b/.github/workflows/e3sm-gh-ci-w-cime-tests.yml index d5687a32b375..f51aa88a34c4 100644 --- a/.github/workflows/e3sm-gh-ci-w-cime-tests.yml +++ b/.github/workflows/e3sm-gh-ci-w-cime-tests.yml @@ -1,4 +1,4 @@ -name: gh +name: gh-w on: pull_request: @@ -17,7 +17,7 @@ concurrency: jobs: - ci-w: + ci: if: ${{ github.repository == 'E3SM-Project/E3SM' }} runs-on: ubuntu-latest strategy: