diff options
| author | Karan Jayachandra <mail@karanjayachandra.com> | 2024-11-09 18:49:40 +0100 |
|---|---|---|
| committer | Karan Jayachandra <mail@karanjayachandra.com> | 2024-11-09 18:49:40 +0100 |
| commit | 14df28d5b8d3d9d80f24c532e1c096f8ac997e5b (patch) | |
| tree | b0b41dd9a9f3d3cd94cb07535410aa99bdfe8507 /src/match_up/utilities.py | |
| parent | bc587d676dca709c8ff8a21470a68938359a7ec8 (diff) | |
Added the random name generation to be part of the package
Diffstat (limited to 'src/match_up/utilities.py')
| -rw-r--r-- | src/match_up/utilities.py | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/src/match_up/utilities.py b/src/match_up/utilities.py index 7a9d55d..8a905ba 100644 --- a/src/match_up/utilities.py +++ b/src/match_up/utilities.py @@ -1,10 +1,11 @@ -from os import getenv from time import time from typing import Tuple from random import shuffle from dataclasses import dataclass + SECS_IN_MIN = 60 +DEFAULT_TIMER = 12.0 def _shuffle_two_lists(a: list, b: list) -> Tuple[list, list]: @@ -30,9 +31,9 @@ def sample_list(indices: list, cost: list[int], count: int = None) -> list: @dataclass class Timer: + max_mins: float = DEFAULT_TIMER ref: float = None running: bool = False - max_mins: float = float(getenv("TIMER")) default: str = ("00", "00") def __post_init__(self): |
