From 0945b1eb845b6236c2aaa787236fa86d9f349c0c Mon Sep 17 00:00:00 2001 From: sanj <67624670+iodrift@users.noreply.github.com> Date: Thu, 25 Jul 2024 01:34:44 -0700 Subject: [PATCH] Auto-update: Thu Jul 25 01:34:44 PDT 2024 --- sijapi/classes.py | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/sijapi/classes.py b/sijapi/classes.py index 1f3caef..b659c46 100644 --- a/sijapi/classes.py +++ b/sijapi/classes.py @@ -33,7 +33,13 @@ def crit(text: str): logger.critical(text) T = TypeVar('T', bound='Configuration') + +BASE_DIR = Path(__file__).resolve().parent +CONFIG_DIR = BASE_DIR / "config" +ENV_PATH = CONFIG_DIR / ".env" +load_dotenv(ENV_PATH) TS_ID = os.environ.get('TS_ID') + class Configuration(BaseModel): HOME: Path = Path.home() _dir_config: Optional['Configuration'] = None