diff --git a/sizebot/lib/versioning.py b/sizebot/lib/versioning.py deleted file mode 100644 index 0944c69e..00000000 --- a/sizebot/lib/versioning.py +++ /dev/null @@ -1,28 +0,0 @@ -from collections.abc import Callable - -from packaging import version - -import sizebot -from sizebot.conf import conf - - -def is_released(v: str) -> bool: - if v is None: - return False - if conf.environment == "development": - try: - bot_v = sizebot.__dev_version__ - except AttributeError: - return True - else: - bot_v = sizebot.__version__ - return version.parse(bot_v) >= version.parse(v) - - -def release_on(release_version: str) -> Callable: - def wrapper(fn: Callable) -> Callable | None: - active = is_released(release_version) - if not active: - return None - return fn - return wrapper