aboutsummaryrefslogtreecommitdiffstats
path: root/app/utils.py
blob: d513ae9127ab12e024b5cf21242016df55b76b37 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
from app.Item import Item


def get_param(key: str, params: dict[str, str]) -> str:
    if key not in params:
        raise Exception(f"no {key} field in config entry: " + str(params))

    return params[key]


def item_to_dict(item: Item) -> dict[str, str]:
    raise NotImplemented()


def dict_to_item(d: dict[str, str]) -> Item:
    raise NotImplemented()