Deltares / Deltares/imod-python
[FEATURE] - Validation settings additional support
Nobody has claimed this yet.
- Dominant language
- Python
- Stars
- 41
- Forks
- 12
- Avg merge
- 21h 8m
- Merged PRs (30d)
- 1
Description
There is a ValidationContext which stores validation settings. Currently constructing a simulation with Modflow6Simulation.from_imod5_data turns off the strict checks for the well and hfb packages.
As noticed before in this PR https://github.com/Deltares/imod-python/pull/1351, this becomes problematic when doing the following:
- Import iMOD5 Simulation
- Dump to netcdfs + toml
- Load dumped simulation
Users can workaround this by doing the following, but this requires setting semi-private attributes:
simulation = imod.mf6.Modflow6Simulation("my_simulation")
simulation._validation_context.strict_hfb_validation = False
The following would enhance configurability:
- Make sure they are dumped to file as well and loaded again.
- Allow turning off this specific validation with a setter method.
Contributor guide
No contributing guide indexed for this repository
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start with ValidationContext and Modflow6Simulation.from_imod5_data to trace how validation settings are created and changed during iMOD5 import. Then inspect the netCDF and TOML dump/load path. Done means the relevant settings survive a dump/load round trip and a public setter can disable the specific validation without using semi-private attributes.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- python
- Domain
- backend
- Issue type
- Feature
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 45/100