Skip to content

Commit

Permalink
🔊 feat: Add Error logging on importing
Browse files Browse the repository at this point in the history
  • Loading branch information
kms0219kms committed Apr 2, 2024
1 parent db5b1a6 commit f7410fc
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions src/bot.py
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
import os
import asyncio
import traceback

from discord import Game, Intents
from discord.ext import commands
Expand All @@ -21,8 +22,8 @@ async def load_extensions():
try:
await bot.load_extension(f"cogs.{file[:-3]}")
print(f"cogs.{file[:-3]} ({file}) ✅")
except Exception as e:
print(f"cogs.{file[:-3]} ({file}) ❌ -> {e}")
except:
print(f"cogs.{file[:-3]} ({file}) ❌ -> {traceback.format_exc()}")

print("------------------------------------")

Expand Down

0 comments on commit f7410fc

Please sign in to comment.