Skip to content

Conversation

@HakonSohoel
Copy link
Contributor

@HakonSohoel HakonSohoel commented Sep 29, 2025

Issue
Resolves #10795

image
  • 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 marked this pull request as draft September 29, 2025 12:55
@codecov-commenter
Copy link

codecov-commenter commented Sep 29, 2025

❌ 1 Tests Failed:

Tests completed Failed Passed Skipped
3404 1 3403 89
View the full list of 1 ❄️ flaky test(s)
tests/ert/unit_tests/config/parsing/test_observations_parser.py::test_parse_observations

Flake rate in main: 88.82% (Passed 17 times, Failed 135 times)

Stack Traces | 0.035s run time
def test_parse_observations():
>       assert parse_observations(
            """
            HISTORY_OBSERVATION FOPR;
    
            SUMMARY_OBSERVATION WOPR_OP1_9
            {
                VALUE   = 0.1;
                ERROR   = 0.05;
                DATE    = 2010-03-31;  -- (RESTART = 9)
                KEY     = WOPR:OP1;
            };
    
            GENERAL_OBSERVATION WPR_DIFF_1 {
               DATA       = SNAKE_OIL_WPR_DIFF;
               INDEX_LIST = 400,800,1200,1800;
               DATE       = 2015-06-13;-- (RESTART = 199)
               OBS_FILE   = wpr_diff_obs.txt;
            };
    
    
            GENERAL_OBSERVATION WPR_DIFF_2 {
               DATA       = SNAKE_OIL_WPR_DIFF;
               INDEX_FILE = wpr_diff_idx.txt;
               DATE       = 2015-06-13;  -- (RESTART = 199)
               OBS_FILE   = wpr_diff_obs.txt;
            };
    
            HISTORY_OBSERVATION  FWPR
            {
               ERROR      = 0.1;
    
               SEGMENT SEG
               {
                  START = 1;
                  STOP  = 0;
                  ERROR = 0.25;
               };
            };--comment
        """,
            "",
        ) == [
            {"type": ObservationType.HISTORY, "name": "FOPR"},
            {
                "type": ObservationType.SUMMARY,
                "name": "WOPR_OP1_9",
                "VALUE": "0.1",
                "ERROR": "0.05",
                "DATE": "2010-03-31",
                "KEY": "WOPR:OP1",
            },
            {
                "type": ObservationType.GENERAL,
                "name": "WPR_DIFF_1",
                "DATA": "SNAKE_OIL_WPR_DIFF",
                "INDEX_LIST": "400,800,1200,1800",
                "DATE": "2015-06-13",
                "OBS_FILE": "wpr_diff_obs.txt",
            },
            {
                "type": ObservationType.GENERAL,
                "name": "WPR_DIFF_2",
                "DATA": "SNAKE_OIL_WPR_DIFF",
                "INDEX_FILE": "wpr_diff_idx.txt",
                "DATE": "2015-06-13",
                "OBS_FILE": "wpr_diff_obs.txt",
            },
            {
                "type": ObservationType.HISTORY,
                "name": "FWPR",
                "ERROR": "0.1",
                "segments": [("SEG", {"START": "1", "STOP": "0", "ERROR": "0.25"})],
            },
        ]

.../config/parsing/test_observations_parser.py:13: 
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 
.../config/parsing/observations_parser.py:55: in parse_observations
    relative_filename = os.path.relpath(filename)
                        ^^^^^^^^^^^^^^^^^^^^^^^^^
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 

path = '', start = None

>   ???
E   ValueError: no path specified

<frozen posixpath>:507: ValueError

To view more test analytics, go to the Test Analytics Dashboard
📋 Got 3 mins? Take this short survey to help us improve Test Analytics.

@codspeed-hq
Copy link

codspeed-hq bot commented Sep 29, 2025

CodSpeed Performance Report

Merging #11946 will not alter performance

Comparing POC-yaml-observations (802f54c) with main (31826f3)

Summary

✅ 22 untouched

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.

Simplified obs.setup with metadata

6 participants