feat(mfusgwel): add comment column support for MfUsgWel package #2695
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Groundwater Vistas (and other preprocessors) commonly export MODFLOW-USG WEL
files with undeclared trailing text after the numeric data — such as well names,
aquifer zone IDs, recharge source identifiers, or other user annotations. These
are not declared AUX variables and are not numeric.
This PR captures that trailing text as comment columns (object dtype) so they
are preserved on read/write roundtrip without being incorrectly declared as
AUX variables in the header.
Example
Input (GWV export, no AUX declared for trailing text):
52901 451.694 70.000 9999 i1_pul
1 -64.360 1150.199 1 PA-001
9999/1→ zone or aquifer ID (comment1)i1_pul/PA-001→ well name (comment2)Changes
flopy_io.py:ulstrd()captures extra tokens beyond declared columnspakbase.py:Package.load()expands dtype with comment columnsmfusgwel.py:_check_for_aux()skips object dtype fields,get_empty()supports comment columns
mfwel.py: parent class aux detection also skips object dtype fields