From 31dd9c86eead713f09803df46335bd4104388893 Mon Sep 17 00:00:00 2001 From: nexy7574 Date: Mon, 27 May 2024 17:23:51 +0100 Subject: [PATCH] Log when a command is being checked --- src/main.py | 22 +++++++++++----------- 1 file changed, 11 insertions(+), 11 deletions(-) diff --git a/src/main.py b/src/main.py index a41c8b7..f24cd74 100644 --- a/src/main.py +++ b/src/main.py @@ -158,17 +158,6 @@ for module in CONFIG["jimmy"].get("modules", ["cogs/*.py"]): log.info(f"Loaded extension {module}") -for command in bot.walk_application_commands(): - try: - assert command.input_type is not None, "Input type was None!" - d = command.to_dict() - except Exception as e: - log.error("Failed to convert %r to dict", command, exc_info=e) - bot.remove_application_command(command) - else: - log.info("Loaded command %r.", command) - - @bot.event async def on_ready(): log.info(f"Logged in as {bot.user} ({bot.user.id})") @@ -287,4 +276,15 @@ if __disabled: else: log.info("No commands to disable. Full steam ahead!") +for command in bot.walk_application_commands(): + log.debug("Checking %r", command) + try: + assert command.input_type is not None, "Input type was None!" + d = command.to_dict() + except Exception as e: + log.error("Failed to convert %r to dict", command, exc_info=e) + bot.remove_application_command(command) + else: + log.debug("Loaded command %r.", command) + bot.run(CONFIG["jimmy"]["token"])