Skip to content

Commit

Permalink
fix(prp): fix incorrectly raised error introduced in 12dea73 (#1921)
Browse files Browse the repository at this point in the history
#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.
  • Loading branch information
wpbonelli authored Jul 3, 2024
1 parent d466c5c commit b76c676
Show file tree
Hide file tree
Showing 7 changed files with 28,994 additions and 14,518 deletions.
26 changes: 26 additions & 0 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -290,6 +290,19 @@ jobs:
pixi run autotest -m "$markers" -k "$filters"
- name: Install executables
if: runner.os == 'Linux'
uses: modflowpy/install-modflow-action@v1

- name: Test mf6 examples
if: runner.os == 'Linux'
working-directory: modflow6
shell: pixi run bash -e {0}
run: |
cp bin/mf6 $(which mf6)
cd ../modflow6-examples/autotest
pytest -v -n auto test_scripts.py
- name: Upload failed test output
if: failure()
uses: actions/upload-artifact@v4
Expand Down Expand Up @@ -416,6 +429,19 @@ jobs:
else
pixi run autotest -m "not large"
fi
- name: Install executables
if: runner.os == 'Linux'
uses: modflowpy/install-modflow-action@v1

- name: Test mf6 examples
if: runner.os == 'Linux'
working-directory: modflow6
shell: pixi run bash -e {0}
run: |
cp bin/mf6 $(which mf6)
cd ../modflow6-examples/autotest
pytest -v -n auto test_scripts.py
- name: Upload failed test output
if: failure()
Expand Down
2 changes: 1 addition & 1 deletion autotest/pytest.ini
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
[pytest]
addopts = --color=yes --benchmark-disable
addopts = --color=yes --benchmark-disable -ra
python_files =
test_*.py
*_test*.py
Expand Down
100 changes: 0 additions & 100 deletions autotest/test_prt_notebooks.py

This file was deleted.

3 changes: 3 additions & 0 deletions environment.yml
Original file line number Diff line number Diff line change
Expand Up @@ -24,13 +24,16 @@ dependencies:
- git+https://github.com/Deltares/xmipy.git
- git+https://github.com/MODFLOW-USGS/modflowapi.git
- git+https://github.com/MODFLOW-USGS/modflow-devtools.git
- pooch
- pyshp
- pytest!=8.1.0
- pytest-benchmark
- pytest-dotenv
- pytest-order
- pytest-xdist
- python
- rasterio
- rasterstats
- scipy
- shapely
- syrupy
Expand Down
Loading

0 comments on commit b76c676

Please sign in to comment.