Skip to content

fix(mflistfile): parse budget values missing the exponent "E" - #2858

Merged
wpbonelli merged 2 commits into
modflowpy:developfrom
wpbonelli:fix-listbudget-missing-exponent
Sep 29, 2026
Merged

wpbonelli merged 2 commits into
modflowpy:developfrom
wpbonelli:fix-listbudget-missing-exponent

Conversation

@wpbonelli

@wpbonelli wpbonelli commented Sep 28, 2026 •

Copy link
Copy Markdown
Member

MF6 list files can contain values with three-digit exponents written without the "E", a Fortran quirk for E/ES formats without an explicit exponent width. This caused ListBudget parsing to fail. Tolerate this when parsing budget lines. MF6 will be fixed too, but list files from existing versions will still contain these values.

Close #2855

wpbonelli and others added 2 commits September 28, 2026 05:20
Fortran E/ES edit descriptors without an exponent width drop the "E"
for three-digit exponents (e.g. 8.5159-100). MF6 list files can
contain such values, which caused ListBudget to fail parsing the
budget. Accept these values when parsing budget lines.

Close modflowpy#2855

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
The parametrized _parse_budget_line test covers the fix, and float32
budget arrays prevent the end-to-end test from checking parsed values.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
@wpbonelli wpbonelli added this to the 3.11.1 milestone Sep 28, 2026
@wpbonelli wpbonelli added the bug label Sep 28, 2026
@codecov

codecov Bot commented Sep 28, 2026 •

Copy link
Copy Markdown

Codecov Report

❌ Patch coverage is 78.57143% with 3 lines in your changes missing coverage. Please review.
✅ Project coverage is 73.7%. Comparing base (556c088) to head (5f3f15e).
⚠️ Report is 235 commits behind head on develop.

Files with missing lines Patch % Lines
flopy/utils/mflistfile.py 78.5% 3 Missing ⚠️
Additional details and impacted files
@@             Coverage Diff             @@
##           develop    #2858      +/-   ##
===========================================
+ Coverage     55.5%    73.7%   +18.2%     
===========================================
  Files          644      659      +15     
  Lines       124135   132398    +8263     
===========================================
+ Hits         68947    97696   +28749     
+ Misses       55188    34702   -20486     
Files with missing lines Coverage Δ
flopy/utils/mflistfile.py 70.2% <78.5%> (+0.7%) ⬆️

... and 585 files with indirect coverage changes

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

@wpbonelli
wpbonelli marked this pull request as ready for review September 28, 2026 20:18
@wpbonelli
wpbonelli merged commit 0901dc0 into modflowpy:develop Sep 29, 2026
25 checks passed
@wpbonelli
wpbonelli deleted the fix-listbudget-missing-exponent branch September 29, 2026 01:15
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

bug: Mf6ListBudget unable to read budget information from first

1 participant