Skip to content

Commit b76c676

Browse files
authored
fix(prp): fix incorrectly raised error introduced in 12dea73 (#1921)
#1907 erroneously converted a cycle condition to an error — this was left over from a more involved refactor which that PR was extracted from, and should not have been included yet. This has caused one of the PRT example models to fail, which has not shown up on this repository's CI because PRT notebook tests were getting skipped due to missing dependencies. This is behind the currently failing FloPy MF6 CI. This PR drops test_prt_notebooks.py in favor of just running the mf6 examples repo's own tests in CI. This is done only on Linux to avoid slowing things down too much, it should not add to total runtime if the runner pool is unsaturated because the modified jobs are still faster than the parallel test jobs. A few dependencies needed by the examples are added to the pixi and conda environments: * pooch * rasterio * rasterstats A subsequent PR will include more extensive cleanup of the release mechanism.
1 parent d466c5c commit b76c676

File tree

7 files changed

+28994
-14518
lines changed

7 files changed

+28994
-14518
lines changed

.github/workflows/ci.yml

Lines changed: 26 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -290,6 +290,19 @@ jobs:
290290
291291
pixi run autotest -m "$markers" -k "$filters"
292292
293+
- name: Install executables
294+
if: runner.os == 'Linux'
295+
uses: modflowpy/install-modflow-action@v1
296+
297+
- name: Test mf6 examples
298+
if: runner.os == 'Linux'
299+
working-directory: modflow6
300+
shell: pixi run bash -e {0}
301+
run: |
302+
cp bin/mf6 $(which mf6)
303+
cd ../modflow6-examples/autotest
304+
pytest -v -n auto test_scripts.py
305+
293306
- name: Upload failed test output
294307
if: failure()
295308
uses: actions/upload-artifact@v4
@@ -416,6 +429,19 @@ jobs:
416429
else
417430
pixi run autotest -m "not large"
418431
fi
432+
433+
- name: Install executables
434+
if: runner.os == 'Linux'
435+
uses: modflowpy/install-modflow-action@v1
436+
437+
- name: Test mf6 examples
438+
if: runner.os == 'Linux'
439+
working-directory: modflow6
440+
shell: pixi run bash -e {0}
441+
run: |
442+
cp bin/mf6 $(which mf6)
443+
cd ../modflow6-examples/autotest
444+
pytest -v -n auto test_scripts.py
419445
420446
- name: Upload failed test output
421447
if: failure()

autotest/pytest.ini

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
[pytest]
2-
addopts = --color=yes --benchmark-disable
2+
addopts = --color=yes --benchmark-disable -ra
33
python_files =
44
test_*.py
55
*_test*.py

autotest/test_prt_notebooks.py

Lines changed: 0 additions & 100 deletions
This file was deleted.

environment.yml

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -24,13 +24,16 @@ dependencies:
2424
- git+https://github.com/Deltares/xmipy.git
2525
- git+https://github.com/MODFLOW-USGS/modflowapi.git
2626
- git+https://github.com/MODFLOW-USGS/modflow-devtools.git
27+
- pooch
2728
- pyshp
2829
- pytest!=8.1.0
2930
- pytest-benchmark
3031
- pytest-dotenv
3132
- pytest-order
3233
- pytest-xdist
3334
- python
35+
- rasterio
36+
- rasterstats
3437
- scipy
3538
- shapely
3639
- syrupy

0 commit comments

Comments
 (0)