From 554e75d8a82a94029defab433fefab7b2e09a0d1 Mon Sep 17 00:00:00 2001 From: Renan Souza Date: Mon, 2 Dec 2024 16:03:48 -0500 Subject: [PATCH] Reformat code --- .../commons/flowcept_dataclasses/workflow_object.py | 7 +++---- src/flowcept/commons/utils.py | 1 + 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/src/flowcept/commons/flowcept_dataclasses/workflow_object.py b/src/flowcept/commons/flowcept_dataclasses/workflow_object.py index 6e093a71..872e02fe 100644 --- a/src/flowcept/commons/flowcept_dataclasses/workflow_object.py +++ b/src/flowcept/commons/flowcept_dataclasses/workflow_object.py @@ -4,9 +4,8 @@ import msgpack from omegaconf import OmegaConf -import flowcept -from flowcept import __version__ - +from flowcept.version import __version__ +from flowcept.commons.utils import get_utc_now from flowcept.configs import ( settings, FLOWCEPT_USER, @@ -71,7 +70,7 @@ def to_dict(self): def enrich(self, adapter_key=None): """Enrich it.""" - self.utc_timestamp = flowcept.commons.utils.get_utc_now() + self.utc_timestamp = get_utc_now() self.flowcept_settings = OmegaConf.to_container(settings) if adapter_key is not None: diff --git a/src/flowcept/commons/utils.py b/src/flowcept/commons/utils.py index cdb3008a..a7e8e427 100644 --- a/src/flowcept/commons/utils.py +++ b/src/flowcept/commons/utils.py @@ -49,6 +49,7 @@ def perf_log(func_name, t0: float, logger=None): return t1 return None + def get_status_from_str(status_str: str) -> Status: """Get the status.""" # TODO: complete this utility function