Skip to content

Conversation

@reneangermeyer
Copy link
Contributor

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 columns
  • pakbase.py: Package.load() expands dtype with comment columns
  • mfusgwel.py: _check_for_aux() skips object dtype fields, get_empty()
    supports comment columns
  • mfwel.py: parent class aux detection also skips object dtype fields

@reneangermeyer reneangermeyer force-pushed the feature/mfusgwel-comment-columns branch from e77c140 to 7554dff Compare January 29, 2026 01:26
@codecov
Copy link

codecov bot commented Jan 29, 2026

Codecov Report

❌ Patch coverage is 82.14286% with 15 lines in your changes missing coverage. Please review.
✅ Project coverage is 72.3%. Comparing base (556c088) to head (0092ae7).
⚠️ Report is 117 commits behind head on develop.

Files with missing lines Patch % Lines
flopy/pakbase.py 78.2% 15 Missing ⚠️
Additional details and impacted files
@@             Coverage Diff             @@
##           develop    #2695      +/-   ##
===========================================
+ Coverage     55.5%    72.3%   +16.8%     
===========================================
  Files          644      667      +23     
  Lines       124135   130552    +6417     
===========================================
+ Hits         68947    94512   +25565     
+ Misses       55188    36040   -19148     
Files with missing lines Coverage Δ
flopy/mfusg/mfusgwel.py 96.2% <100.0%> (+4.4%) ⬆️
flopy/modflow/mfwel.py 87.7% <100.0%> (-2.3%) ⬇️
flopy/utils/flopy_io.py 72.3% <100.0%> (-3.1%) ⬇️
flopy/pakbase.py 82.1% <78.2%> (-2.4%) ⬇️

... and 559 files with indirect coverage changes

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.

@reneangermeyer reneangermeyer marked this pull request as ready for review January 29, 2026 11:35
@wpbonelli wpbonelli added this to the 3.11 milestone Jan 29, 2026
@jdhughes-dev
Copy link
Contributor

This needs a test to confirm read/write with comments. Also would need a test of adding comments to a fresh model instance.

Captures undeclared trailing text in MODFLOW-USG WEL files (common in
Groundwater Vistas exports) as comment columns with object dtype. Comments
are preserved on read/write roundtrip without being declared as AUX in the
header.
@reneangermeyer reneangermeyer force-pushed the feature/mfusgwel-comment-columns branch from 7554dff to 0092ae7 Compare January 29, 2026 21:06
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants