From 6ca50c193e1ddb20aaab50b91bd182caec7e0bbe Mon Sep 17 00:00:00 2001 From: Tom Vo Date: Mon, 23 Sep 2024 11:14:10 -0700 Subject: [PATCH 1/2] Update build workflow - Replace mamba with miniforge and conda - Add Python 3.12 to testing matrix - Update `CANCEL_OTHERS` to `false` to test each Python version individually for potential Python-specific issues - Update `setup-miniconda` to v3 --- .github/workflows/build_workflow.yml | 16 +++++++--------- 1 file changed, 7 insertions(+), 9 deletions(-) diff --git a/.github/workflows/build_workflow.yml b/.github/workflows/build_workflow.yml index e8943794..7a8219cb 100644 --- a/.github/workflows/build_workflow.yml +++ b/.github/workflows/build_workflow.yml @@ -10,7 +10,7 @@ on: workflow_dispatch: env: - CANCEL_OTHERS: true + CANCEL_OTHERS: False PATHS_IGNORE: '["**/README.rst", "**/AUTHORS.rst", "**/CODE_OF_CONDUCT.rst", "**/HISTORY.rst", "**/CONTRIBUTING.rst", "**/docs/**", "**/ISSUE_TEMPLATE/**", "**/pull_request_template.md", "**/.vscode/**"]' jobs: @@ -31,7 +31,7 @@ jobs: needs: skip-duplicate-actions if: needs.skip-duplicate-actions.outputs.should_skip != 'true' runs-on: ubuntu-latest - timeout-minutes: 3 + timeout-minutes: 5 steps: - name: Checkout Code Repository uses: actions/checkout@v3 @@ -55,18 +55,16 @@ jobs: shell: bash -l {0} strategy: matrix: - python-version: ["3.9", "3.10", "3.11"] + python-version: ["3.9", "3.10", "3.11", "3.12"] steps: - uses: actions/checkout@v3 - name: Set up Conda Environment - uses: conda-incubator/setup-miniconda@v2 + uses: conda-incubator/setup-miniconda@v3 with: - miniforge-variant: Mambaforge + miniforge-variant: Miniforge3 miniforge-version: latest activate-environment: "xcdat_ci" - use-mamba: true - mamba-version: "*" channel-priority: strict auto-update-conda: true python-version: ${{ matrix.python-version }} @@ -93,10 +91,10 @@ jobs: - if: steps.cache.outputs.cache-hit != 'true' name: Update environment run: | - mamba env update -n xcdat_ci -f conda-env/ci.yml + conda env update -n xcdat_ci -f conda-env/ci.yml # Make sure the Python version in the env matches the current matrix version. # Make sure numpy is not > 2.0. - mamba install -c conda-forge python=${{ matrix.python-version }} "numpy>=1.23.0,<2.0" + conda install -c conda-forge python=${{ matrix.python-version }} "numpy>=1.23.0,<2.0" - name: Install xcdat # Source: https://github.com/conda/conda-build/issues/4251#issuecomment-1053460542 From aacf61fc617a9df037d64dda1b4b80169b0334f8 Mon Sep 17 00:00:00 2001 From: Tom Vo Date: Mon, 23 Sep 2024 11:16:25 -0700 Subject: [PATCH 2/2] Apply suggestions from code review --- .github/workflows/build_workflow.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/build_workflow.yml b/.github/workflows/build_workflow.yml index 7a8219cb..3481f0b3 100644 --- a/.github/workflows/build_workflow.yml +++ b/.github/workflows/build_workflow.yml @@ -10,7 +10,7 @@ on: workflow_dispatch: env: - CANCEL_OTHERS: False + CANCEL_OTHERS: false PATHS_IGNORE: '["**/README.rst", "**/AUTHORS.rst", "**/CODE_OF_CONDUCT.rst", "**/HISTORY.rst", "**/CONTRIBUTING.rst", "**/docs/**", "**/ISSUE_TEMPLATE/**", "**/pull_request_template.md", "**/.vscode/**"]' jobs: