From ca82bc2e222fe4f19be74e620e7dd67cb9ec72d4 Mon Sep 17 00:00:00 2001 From: xjules Date: Tue, 17 Oct 2023 13:56:46 +0200 Subject: [PATCH] Remove unused util functions --- src/_ert_job_runner/util/__init__.py | 31 +++------------------------- 1 file changed, 3 insertions(+), 28 deletions(-) diff --git a/src/_ert_job_runner/util/__init__.py b/src/_ert_job_runner/util/__init__.py index 8e38745bd72..917c9727b18 100644 --- a/src/_ert_job_runner/util/__init__.py +++ b/src/_ert_job_runner/util/__init__.py @@ -1,28 +1,3 @@ -import os - - -def read_os_release(pfx="LSB_"): - fname = "/etc/os-release" - if not os.path.isfile(fname): - return {} - - def processline(ln): - return ln.strip().replace('"', "") - - def splitline(ln, pfx=""): - if ln.count("=") == 1: - k, v = ln.split("=") - return pfx + k, v - return None - - props = {} - with open(fname, "r", encoding="utf-8") as f: - for line in f: - kv = splitline(processline(line), pfx=pfx) - if kv: - props[kv[0]] = kv[1] - return props - - -def pad_nonexisting(path, pad="-- "): - return path if os.path.exists(path) else pad + path +""" +util contains helping functions to create job statuses. +"""