Skip to content
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

ci(parallel): skip test_par_gwf02 cases d-f, no xdist on windows #1960

Merged
merged 3 commits into from
Jul 24, 2024
Merged
Show file tree
Hide file tree
Changes from 2 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: 1 addition & 1 deletion .github/common/test_modflow6.bat
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
cd "%GITHUB_WORKSPACE%\modflow6\autotest"
where libpetsc.dll
ldd ..\bin\mf6
pixi run autotest --parallel -k "test_par" -m "%MARKERS%"
pixi run pytest -v --durations=0 --keep-failed .failed --parallel -k "test_par" -m "%MARKERS%"
82 changes: 52 additions & 30 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -46,10 +46,11 @@ jobs:
runs-on: ubuntu-latest
steps:

- name: Checkout modflow6
- name: Checkout MF6
uses: actions/checkout@v4

- uses: prefix-dev/setup-pixi@v0.8.1
- name: Setup pixi
uses: prefix-dev/setup-pixi@v0.8.1
with:
pixi-version: v0.24.2

Expand All @@ -76,7 +77,7 @@ jobs:
FC_V: 13
steps:

- name: Checkout modflow6
- name: Checkout MF6
uses: actions/checkout@v4

- name: Setup ${{ env.FC }} ${{ env.FC_V }}
Expand All @@ -85,21 +86,22 @@ jobs:
compiler: gcc
version: ${{ env.FC_V }}

- uses: prefix-dev/setup-pixi@v0.8.1
- name: Setup pixi
uses: prefix-dev/setup-pixi@v0.8.1
with:
pixi-version: v0.24.2

- name: Meson setup
- name: Setup MF6
run: pixi run setup -Dwerror=true builddir

- name: Meson compile
- name: Build MF6
run: pixi run build builddir

- name: Show build log
if: failure()
run: cat builddir/meson-logs/meson-log.txt

- name: Meson test
- name: Unit test MF6
run: pixi run test builddir

smoke_test:
Expand All @@ -112,7 +114,7 @@ jobs:
FC: gfortran
FC_V: 13
steps:
- name: Checkout modflow6
- name: Checkout MF6
uses: actions/checkout@v4
with:
path: modflow6
Expand Down Expand Up @@ -146,7 +148,7 @@ jobs:
pixi run --manifest-path=../modflow6/pixi.toml meson install -C builddir
echo "PKG_CONFIG_PATH=$(pwd)/lib/pkgconfig:$PKG_CONFIG_PATH" >> $GITHUB_ENV

- name: Build modflow6
- name: Build MF6
working-directory: modflow6
run: |
pixi run setup builddir
Expand All @@ -157,7 +159,7 @@ jobs:
working-directory: modflow6
run: cat builddir/meson-logs/meson-log.txt

- name: Unit test programs
- name: Unit test MF6
working-directory: modflow6
run: pixi run test builddir

Expand All @@ -171,7 +173,7 @@ jobs:
GITHUB_TOKEN: ${{ github.token }}
run: pixi run get-exes

- name: Test programs
- name: Test MF6
working-directory: modflow6
run: |
if [ "${{ github.ref_name }}" == "master" ]; then
Expand All @@ -188,7 +190,7 @@ jobs:
path: modflow6/autotest/.failed

test_gfortran:
name: Test gnu fortran
name: Test GNU fortran
needs:
- lint
- build
Expand All @@ -205,18 +207,18 @@ jobs:
FC: gfortran
FC_V: 13
steps:
- name: Checkout modflow6
- name: Checkout MF6
uses: actions/checkout@v4
with:
path: modflow6

- name: Checkout modflow6-testmodels
- name: Checkout test models
uses: actions/checkout@v4
with:
repository: MODFLOW-USGS/modflow6-testmodels
path: modflow6-testmodels

- name: Checkout modflow6-examples
- name: Checkout examples
uses: actions/checkout@v4
with:
repository: MODFLOW-USGS/modflow6-examples
Expand Down Expand Up @@ -247,7 +249,7 @@ jobs:
echo "LDFLAGS=$ldflags" >> $GITHUB_ENV
fi

- name: Build modflow6
- name: Build MF6
working-directory: modflow6
run: |
setupargs=""
Expand All @@ -262,7 +264,7 @@ jobs:
working-directory: modflow6
run: cat builddir/meson-logs/meson-log.txt

- name: Unit test programs
- name: Unit test MF6
working-directory: modflow6
run: pixi run test builddir

Expand All @@ -276,7 +278,7 @@ jobs:
GITHUB_TOKEN: ${{ github.token }}
run: pixi run get-exes

- name: Test modflow6
- name: Test MF6
working-directory: modflow6
env:
REPOS_PATH: ${{ github.workspace }}
Expand All @@ -300,7 +302,7 @@ jobs:
if: runner.os == 'Linux'
uses: modflowpy/install-modflow-action@v1

- name: Test mf6 examples
- name: Test MF6 examples
if: runner.os == 'Linux'
working-directory: modflow6
shell: pixi run bash -e {0}
Expand Down Expand Up @@ -345,7 +347,7 @@ jobs:
run: pixi run test-dist-scripts

test_intel_fortran:
name: Test intel fortran
name: Test Intel fortran
needs:
- lint
- build
Expand All @@ -363,18 +365,18 @@ jobs:
shell: bash
steps:

- name: Checkout modflow6
- name: Checkout MF6
uses: actions/checkout@v4
with:
path: modflow6

- name: Checkout modflow6-testmodels
- name: Checkout test models
uses: actions/checkout@v4
with:
repository: MODFLOW-USGS/modflow6-testmodels
path: modflow6-testmodels

- name: Checkout modflow6-examples
- name: Checkout examples
uses: actions/checkout@v4
with:
repository: MODFLOW-USGS/modflow6-examples
Expand All @@ -400,7 +402,7 @@ jobs:
working-directory: modflow6
run: pixi run update-version

- name: Build modflow6
- name: Build MF6
working-directory: modflow6
run: |
pixi run setup builddir
Expand All @@ -411,7 +413,7 @@ jobs:
working-directory: modflow6
run: cat builddir/meson-logs/meson-log.txt

- name: Unit test programs
- name: Unit test MF6
working-directory: modflow6
run: pixi run test builddir

Expand All @@ -425,7 +427,7 @@ jobs:
GITHUB_TOKEN: ${{ github.token }}
run: pixi run get-exes

- name: Test programs
- name: Test MF6
working-directory: modflow6
env:
REPOS_PATH: ${{ github.workspace }}
Expand All @@ -440,7 +442,7 @@ jobs:
if: runner.os == 'Linux'
uses: modflowpy/install-modflow-action@v1

- name: Test mf6 examples
- name: Test examples
if: runner.os == 'Linux'
working-directory: modflow6
shell: pixi run bash -e {0}
Expand Down Expand Up @@ -479,7 +481,7 @@ jobs:

steps:

- name: Checkout modflow6
- name: Checkout MF6
uses: actions/checkout@v4
with:
path: modflow6
Expand All @@ -502,6 +504,26 @@ jobs:
if: runner.os == 'Windows'
uses: ./modflow6/.github/actions/test-par-win

- name: Test serial MF6
working-directory: modflow6
env:
REPOS_PATH: ${{ github.workspace }}
run: |
markers=""
if [[ "${{ github.ref_name }}" == "master" ]]; then
markers="not large and not developmode"
else
markers="not large"
fi

filters=""
if [[ "${{ matrix.os }}" == "macos-14" ]]; then
# comparison fails on macos-14 with optimization=1
filters="not test028_sfr_rewet"
fi

pixi run autotest -m "$markers" -k "$filters"

- name: Upload failed test output
if: failure()
uses: actions/upload-artifact@v4
Expand All @@ -526,7 +548,7 @@ jobs:

steps:

- name: Checkout modflow6
- name: Checkout MF6
uses: actions/checkout@v4
with:
path: modflow6
Expand All @@ -545,7 +567,7 @@ jobs:
working-directory: modflow6
run: pixi run pip install xugrid xarray netcdf4

- name: Test Extended MF6
- name: Test extended MF6
uses: ./modflow6/.github/actions/test-extended

- name: Upload failed test output
Expand Down
5 changes: 5 additions & 0 deletions autotest/test_par_gwf02.py
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,8 @@
no matter the topology of partitions
"""

from platform import system

import flopy
import numpy as np
import pytest
Expand Down Expand Up @@ -239,6 +241,9 @@ def check_output(idx, test):
@pytest.mark.parallel
@pytest.mark.parametrize("idx, name", enumerate(cases))
def test_mf6model(idx, name, function_tmpdir, targets):
if system() == "Windows" and name.endswith(("d", "e", "f")):
pytest.skip("very slow on windows runners")

ncpus = domain_grid[idx][0] * domain_grid[idx][1]
test = TestFramework(
name=name,
Expand Down
Loading