From e2b0c0ea89a2162ea62d7383243ebe7b9e6ea657 Mon Sep 17 00:00:00 2001 From: alwayscompiling Date: Fri, 29 Jul 2022 14:25:25 -0400 Subject: [PATCH] Enforcing python version because ordered dicts in 3.7 is required. --- highscores.py | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/highscores.py b/highscores.py index 6cc103a..edec65b 100644 --- a/highscores.py +++ b/highscores.py @@ -4,6 +4,7 @@ main file for pvm-highscores bot import logging import os +import sys import nextcord from nextcord.ext import commands @@ -32,6 +33,11 @@ submission_objects: dict = {} def main(): """Main function for bot.""" + min_python_version = (3, 7) + if sys.version_info < min_python_version: + print("ERROR: Python version must be >= 3.7") + sys.exit() + # Allows privledged intents for monitoring members joining, roles editing, and role assignments # These need to be enabled in the developer portal as well intents = nextcord.Intents.default()