WIP refactor logic

This commit is contained in:
msramalho
2022-11-15 15:00:52 +00:00
parent 6a0ce5ced1
commit 65dd155c90
12 changed files with 320 additions and 39 deletions

View File

@@ -1,3 +1,4 @@
# we need to explicitly expose the available imports here
from .gworksheet import *
from .misc import *
from .misc import *
from .util import Util

20
src/utils/util.py Normal file
View File

@@ -0,0 +1,20 @@
from __future__ import annotations
from dataclasses import dataclass
from abc import abstractmethod, ABC
from metadata import Metadata
from step import Step
@dataclass
class Util(Step, ABC):
name = "util"
def __init__(self, config: dict) -> None:
Step.__init__(self)
# only for typing...
def init(name: str, config: dict) -> Util:
return super().init(name, config, Util)
@abstractmethod
def enrich(self, item: Metadata) -> Metadata: pass