From 35f69170a048599ce74a04a42d65cb8a0e20e3b8 Mon Sep 17 00:00:00 2001 From: Stefaan Lippens Date: Mon, 7 Oct 2024 07:57:34 +0200 Subject: [PATCH] fixup! Issue #635: cleaner job manager API for initializing the job database --- openeo/extra/job_management.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/openeo/extra/job_management.py b/openeo/extra/job_management.py index 88cc11a17..f98ccb3e7 100644 --- a/openeo/extra/job_management.py +++ b/openeo/extra/job_management.py @@ -259,7 +259,7 @@ def _make_resilient(connection): connection.session.mount("http://", HTTPAdapter(max_retries=retries)) @staticmethod - def __normalize_df__(df: pd.DataFrame) -> pd.DataFrame: + def _normalize_df(df: pd.DataFrame) -> pd.DataFrame: """ Normalize given pandas dataframe (creating a new one): ensure we have the required columns. @@ -713,7 +713,7 @@ def initialize_from_df(self, df: pd.DataFrame): # TODO: option to provide custom MultiBackendJobManager subclass with custom normalize? if self.exists(): raise RuntimeError(f"Job database {self!r} already exists.") - df = MultiBackendJobManager.__normalize_df__(df) + df = MultiBackendJobManager._normalize_df(df) self.persist(df) # Return self to allow chaining with constructor. return self