Clean up type hints everywhere, overhaul bot configuration
Some checks failed
Build Heidi Docker image / build-docker (push) Failing after 28s

This commit is contained in:
2025-09-23 20:39:11 +02:00
parent 591f4ea191
commit 6659079d7a
5 changed files with 331 additions and 183 deletions

View File

@ -1,29 +1,28 @@
import os
import discord
from discord.object import Object
from dotenv import load_dotenv
# This is run when this file is imported
load_dotenv()
HAS_VARIABLES: bool = load_dotenv()
print("Debug: Importing heidi_constants.py")
# ================================================================================================ #
# ================================================================================================ #
# NOTE: Always set this correctly:
DOCKER = os.getenv("DOCKER") == "True"
# ================================================================================================ #
# ================================================================================================ #
# =========================================================================== #
# =========================================================================== #
DOCKER: bool = os.getenv("DOCKER") == str(True)
# =========================================================================== #
# =========================================================================== #
# Constants
CONFIGPATH = "/config" if DOCKER else "."
USERCONFIGNAME = "Heidi_User.conf"
CONFIGPATH: str = "/config" if DOCKER else "."
USERCONFIGNAME: str = "Heidi_User.conf"
SOUNDDIR: str = "/sounds" if DOCKER else "./heidi-sounds"
# IDs of the servers Heidi is used on
LINUS_GUILD = discord.Object(id=431154792308408340)
TEST_GUILD = discord.Object(id=821511861178204161)
LINUS_GUILD: Object = Object(id=431154792308408340)
TEST_GUILD: Object = Object(id=821511861178204161)
# Channel IDs
HEIDI_SPAM_ID = 822223476101742682
HEIDI_SPAM_ID: int = 822223476101742682