Skip to content

Conversation

@HakonSohoel
Copy link
Contributor

@HakonSohoel HakonSohoel commented Jan 20, 2026

A value of -1 and error of 0 is used by fmu.tools.rms create_rft_ertobs to indicate missing data. If encountered in an rft observations csv file it should be skipped and create a user warning.

Issue
Resolves #12448

Approach
Added test to ensure rows with value -1 and error 0 are skipped with a warning
and added required functionality.

  • PR title captures the intent of the changes, and is fitting for release notes.
  • Added appropriate release note label
  • Commit history is consistent and clean, in line with the contribution guidelines.
  • Make sure unit tests pass locally after every commit (git rebase -i main --exec 'just rapid-tests')

When applicable

  • When there are user facing changes: Updated documentation
  • New behavior or changes to existing untested code: Ensured that unit tests are added (See Ground Rules).
  • Large PR: Prepare changes in small commits for more convenient review
  • Bug fix: Add regression test for the bug
  • Bug fix: Add backport label to latest release (format: 'backport release-branch-name')

@HakonSohoel HakonSohoel added the release-notes:unreleased-feature-changes PR with changes to a feature which is not yet released. Not for introduction of new features! label Jan 20, 2026
@HakonSohoel HakonSohoel force-pushed the ensure-compatibility-with-create_rft_ertobs-handling-of-missing-data branch 2 times, most recently from fa46661 to ab3652c Compare January 20, 2026 10:01
A value of -1 and error of 0 is used by fmu.tools.rms create_rft_ertobs
to indicate missing data. If encountered in an rft observations csv file
it should be skipped and create a user warning.
@HakonSohoel HakonSohoel force-pushed the ensure-compatibility-with-create_rft_ertobs-handling-of-missing-data branch from ab3652c to 91b5825 Compare January 20, 2026 10:05
@eivindjahren
Copy link
Contributor

I guess we will need this workaround for a while at least, but should we also change the creation of the csv file so that it does not include rows that are not correct? Thoughts @oyvindeide & @berland ?

@codecov-commenter
Copy link

codecov-commenter commented Jan 20, 2026

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 90.64%. Comparing base (f0d9de4) to head (91b5825).
⚠️ Report is 2 commits behind head on main.

Additional details and impacted files
@@            Coverage Diff             @@
##             main   #12676      +/-   ##
==========================================
- Coverage   90.68%   90.64%   -0.04%     
==========================================
  Files         429      429              
  Lines       29808    29816       +8     
==========================================
- Hits        27030    27028       -2     
- Misses       2778     2788      +10     
Flag Coverage Δ
cli-tests 37.55% <11.11%> (-0.01%) ⬇️
gui-tests 69.35% <11.11%> (-0.01%) ⬇️
performance-and-unit-tests 73.93% <100.00%> (+<0.01%) ⬆️
test 38.06% <11.11%> (-0.01%) ⬇️

Flags with carried forward coverage won't be shown. Click here to find out more.

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

@codspeed-hq
Copy link

codspeed-hq bot commented Jan 20, 2026

CodSpeed Performance Report

Merging this PR will not alter performance

Comparing HakonSohoel:ensure-compatibility-with-create_rft_ertobs-handling-of-missing-data (91b5825) with main (b34e318)

Summary

✅ 22 untouched benchmarks

ConfigWarning.warn(
(
f"Value=-1 and error=0 detected for well {row.WELL_NAME} "
f"at date {row.DATE} in {filename}. The row will be ignored"
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

"row" is an implementation detail. Should probably say something along: "The observation at that date will be ignored"

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

release-notes:unreleased-feature-changes PR with changes to a feature which is not yet released. Not for introduction of new features!

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Check compatibility with create_rft_ertobs handling of missing data

4 participants