From 17af1ae6ca22d3bf76d09705cb3f29b17dbfdab7 Mon Sep 17 00:00:00 2001 From: "bozo.kopic" Date: Fri, 25 Mar 2022 21:18:41 +0100 Subject: WIP server --- src_py/hatter/common.py | 22 ++++++++++++++++++++++ 1 file changed, 22 insertions(+) (limited to 'src_py/hatter/common.py') diff --git a/src_py/hatter/common.py b/src_py/hatter/common.py index cf99bb9..1b1de47 100644 --- a/src_py/hatter/common.py +++ b/src_py/hatter/common.py @@ -1,4 +1,6 @@ from pathlib import Path +import enum +import typing from hat import json @@ -8,3 +10,23 @@ package_path: Path = Path(__file__).parent json_schema_repo: json.SchemaRepository = json.SchemaRepository( json.json_schema_repo, json.SchemaRepository.from_json(package_path / 'json_schema_repo.json')) + + +class Order(enum.Enum): + ASC = 'ASC' + DESC = 'DESC' + + +class Status(enum.Enum): + PENDING = 0 + RUNNING = 1 + SUCCESS = 2 + FAILURE = 3 + + +class Commit(typing.NamedTuple): + repo: str + hash: str + change: float + status: Status + output: str -- cgit v1.2.3-70-g09d2