Skip to content

Replace old client with new storage api - #14271

Open
eqbech wants to merge 1 commit into
replace-plot-api-with-storage-apifrom
replace-remaining-usages-of-old-client
Open

Replace old client with new storage api#14271
eqbech wants to merge 1 commit into
replace-plot-api-with-storage-apifrom
replace-remaining-usages-of-old-client

Conversation

@eqbech

@eqbech eqbech commented Aug 25, 2026

Copy link
Copy Markdown
Contributor

Issue
Resolves #14244

Approach
Short description of the approach

(Screenshot of new behavior in GUI if applicable)

  • 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 screenshots are changed: Review screenshot-PR in ert-testdata,
    merge screenshot-PR in ert-testdata before merging this PR.
  • 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')

Stack created with GitHub Stacks CLIGive Feedback 💬

@codecov-commenter

codecov-commenter commented Aug 25, 2026

Copy link
Copy Markdown

❌ 1 Tests Failed:

Tests completed Failed Passed Skipped
4259 1 4258 63
View the top 1 failed test(s) by shortest run time
tests/everest/test_everest_client.py::test_that_multiple_everest_clients_can_connect_to_server@math_func/config_minimal.yml
Stack Traces | 490s run time
cached_example = <function cached_example.<locals>.run_config at 0x7fdac91174c0>
change_to_tmpdir = None

    @pytest.mark.skip_mac_ci
    @pytest.mark.slow
    @pytest.mark.xdist_group("math_func/config_minimal.yml")
    @pytest.mark.flaky(rerun=3)
    @pytest.mark.skipif(
        sys.version_info[0:3] == (3, 13, 6), reason="Fails on Python 3.13.6"
    )
    def test_that_multiple_everest_clients_can_connect_to_server(
        cached_example, change_to_tmpdir
    ):
        # We use a cached run for the reference list of received events
        path, config_file, _, server_events_list = cached_example(
            "math_func/config_minimal.yml"
        )
    
        config_path = Path(path) / config_file
        config_content = yaml.safe_load(config_path.read_text(encoding="utf-8"))
        config_content["simulator"] = {"queue_system": {"name": "local", "max_running": 2}}
        config_path.write_text(
            yaml.dump(config_content, default_flow_style=False), encoding="utf-8"
        )
    
        ever_config = EverestConfig.load_file(config_path)
    
        # Run the case through everserver
        everest_main_thread = threading.Thread(
            target=everest_entry, args=[[str(config_path)]]
        )
    
        everest_main_thread.start()
>       api = ErtClient.for_project(
            Path(ServerConfig.get_session_dir(ever_config.output_dir))
        )

.../tests/everest/test_everest_client.py:194: 
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 
.../ert/services/ert_client.py:102: in for_project
    return cls(SharedClient.get_client(project, connect_timeout), timeout)
               ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
.../ert/services/shared_client.py:58: in get_client
    client = create_ertserver_client(key, timeout=timeout)
             ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
.../ert/services/shared_client.py:140: in create_ertserver_client
    controller = create_ert_server_controller(timeout=timeout, project=project)
                 ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 

project = PosixPath('.../everest-0/everest_output/.session')
timeout = 240, logging_config = None

    def create_ert_server_controller(
        *,
        project: os.PathLike[str],
        timeout: int | None = None,
        logging_config: str | None = None,
    ) -> ErtServerController:
        path = Path(project)
        # Wait for storage_server.json file to appear
        try:  # ruff: ignore[too-many-statements-in-try-clause]
            if timeout is None:
                timeout = 240
            t = -1
            while t < timeout:
                storage_server_path = path / _ERT_SERVER_CONNECTION_INFO_FILE
                try:
                    if storage_server_path.stat().st_size > 0:
                        storage_server_content = json.loads(
                            storage_server_path.read_text(encoding="utf-8")
                        )
    
                        return ErtServerController(
                            storage_path=str(path),
                            connection_info=storage_server_content,
                            logging_config=logging_config,
                        )
                except FileNotFoundError:
                    pass
    
                sleep(1)
                t += 1
    
>           raise TimeoutError("Server not started")
E           TimeoutError: Server not started

.../ert/services/ert_server.py:452: TimeoutError

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

@eqbech
eqbech force-pushed the replace-remaining-usages-of-old-client branch 2 times, most recently from 064fb1c to 5d7bc5d Compare August 25, 2026 12:59
@eqbech
eqbech force-pushed the replace-remaining-usages-of-old-client branch from 5d7bc5d to 162cc46 Compare August 26, 2026 07:07
@eqbech
eqbech force-pushed the replace-remaining-usages-of-old-client branch 2 times, most recently from 6a2232a to 97ba598 Compare August 27, 2026 06:01
@eqbech
eqbech force-pushed the replace-remaining-usages-of-old-client branch from 97ba598 to 4219e66 Compare August 27, 2026 06:03
@eqbech
eqbech force-pushed the replace-remaining-usages-of-old-client branch from 4219e66 to af7b1cf Compare August 27, 2026 06:16
@eqbech
eqbech force-pushed the replace-remaining-usages-of-old-client branch from af7b1cf to 68c2bb8 Compare August 27, 2026 06:36
@ertomatic

Copy link
Copy Markdown
Collaborator

Screenshots differ from baselines. A baseline update PR has been prepared: equinor/ert-testdata#98

@eqbech
eqbech force-pushed the replace-remaining-usages-of-old-client branch from 68c2bb8 to c71a082 Compare August 27, 2026 07:30
@ertomatic

Copy link
Copy Markdown
Collaborator

Screenshot tests now pass. The baseline update PR equinor/ert-testdata#98 has been closed.

@eqbech
eqbech force-pushed the replace-remaining-usages-of-old-client branch from c71a082 to c414c17 Compare August 27, 2026 08:45
Comment thread src/everest/bin/everest_script.py Outdated
@eqbech
eqbech force-pushed the replace-remaining-usages-of-old-client branch 3 times, most recently from 80eab06 to 45ba4c8 Compare August 27, 2026 11:10
@eqbech
eqbech force-pushed the replace-remaining-usages-of-old-client branch from 45ba4c8 to c096914 Compare August 27, 2026 12:40
@eqbech
eqbech force-pushed the replace-remaining-usages-of-old-client branch from fe95736 to b5e88ea Compare August 31, 2026 07:48
ertomatic pushed a commit to equinor/ert-testdata that referenced this pull request Aug 31, 2026
ertomatic pushed a commit to equinor/ert-testdata that referenced this pull request Aug 31, 2026
@eqbech
eqbech force-pushed the replace-remaining-usages-of-old-client branch from b5e88ea to 9ae533c Compare August 31, 2026 11:04
ertomatic pushed a commit to equinor/ert-testdata that referenced this pull request Aug 31, 2026
@eqbech
eqbech force-pushed the replace-remaining-usages-of-old-client branch from 9ae533c to 41f6d83 Compare August 31, 2026 13:04
ertomatic pushed a commit to equinor/ert-testdata that referenced this pull request Aug 31, 2026
@eqbech
eqbech force-pushed the replace-remaining-usages-of-old-client branch from 41f6d83 to a822928 Compare August 31, 2026 13:33
ertomatic pushed a commit to equinor/ert-testdata that referenced this pull request Aug 31, 2026
@eqbech
eqbech force-pushed the replace-remaining-usages-of-old-client branch from a822928 to 083a08b Compare August 31, 2026 14:00
@eqbech
eqbech force-pushed the replace-remaining-usages-of-old-client branch from 083a08b to 6b318c7 Compare August 31, 2026 14:03
ertomatic pushed a commit to equinor/ert-testdata that referenced this pull request Aug 31, 2026
ertomatic pushed a commit to equinor/ert-testdata that referenced this pull request Aug 31, 2026
@ertomatic

Copy link
Copy Markdown
Collaborator

Screenshot tests now pass. The baseline update PR equinor/ert-testdata#104 has been closed.

@ertomatic

Copy link
Copy Markdown
Collaborator

Screenshots differ from baselines. A baseline update PR has been prepared: equinor/ert-testdata#109

ertomatic pushed a commit to equinor/ert-testdata that referenced this pull request Sep 1, 2026
@eqbech
eqbech force-pushed the replace-remaining-usages-of-old-client branch from dac0e5c to 6b52f10 Compare September 1, 2026 10:46
@ertomatic

Copy link
Copy Markdown
Collaborator

Screenshot tests now pass. The baseline update PR equinor/ert-testdata#109 has been closed.

@eqbech
eqbech force-pushed the replace-remaining-usages-of-old-client branch from 6b52f10 to 96a85fe Compare September 1, 2026 12:08
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.

Create a common ert/everest client

4 participants