From cb4fe81a2aab08d48114e96cb6052a4c9d63e2ad Mon Sep 17 00:00:00 2001 From: object-Object Date: Sun, 15 Sep 2024 18:35:20 -0400 Subject: [PATCH] Fix APICog not being hashable --- bot/src/ghutils/cogs/api.py | 2 +- bot/src/ghutils/core/cog.py | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/bot/src/ghutils/cogs/api.py b/bot/src/ghutils/cogs/api.py index 1739dd5..2b8e771 100644 --- a/bot/src/ghutils/cogs/api.py +++ b/bot/src/ghutils/cogs/api.py @@ -121,7 +121,7 @@ async def get_login( return HTMLResponse(SUCCESS_PAGE) -@dataclass +@dataclass(eq=False) class APICog(GHUtilsCog): server: Server | None = field(default=None, init=False) diff --git a/bot/src/ghutils/core/cog.py b/bot/src/ghutils/core/cog.py index 572f4df..dfc1c91 100644 --- a/bot/src/ghutils/core/cog.py +++ b/bot/src/ghutils/core/cog.py @@ -20,7 +20,7 @@ def __new__(cls, *args: Any, **kwargs: Any) -> CogMeta: return super().__new__(cls, *args, **kwargs) -@dataclass +@dataclass(eq=False) class GHUtilsCog(Cog, metaclass=GHUtilsCogMeta): """Base class for GHUtils cogs.