diff --git a/docs/wavelink.rst b/docs/wavelink.rst index 73eaf0ba..da5374dd 100644 --- a/docs/wavelink.rst +++ b/docs/wavelink.rst @@ -475,7 +475,7 @@ Exceptions ---------- status: int The response status code. - reason: str | None + error: str | None The response reason. Could be ``None`` if no reason was provided. .. py:exception:: LavalinkLoadException diff --git a/uv.lock b/uv.lock index d5a4486f..a1b41298 100644 --- a/uv.lock +++ b/uv.lock @@ -653,7 +653,7 @@ wheels = [ [[package]] name = "wavelink" -version = "3.5.1" +version = "3.5.2" source = { editable = "." } dependencies = [ { name = "aiohttp" }, diff --git a/wavelink/exceptions.py b/wavelink/exceptions.py index dc6b5805..c991f20d 100644 --- a/wavelink/exceptions.py +++ b/wavelink/exceptions.py @@ -94,14 +94,14 @@ class LavalinkException(WavelinkException): ---------- status: int The response status code. - reason: str | None + error: str | None The response reason. Could be ``None`` if no reason was provided. """ def __init__(self, msg: str | None = None, /, *, data: ErrorResponse) -> None: self.timestamp: int = data["timestamp"] self.status: int = data["status"] - self.error: str = data["error"] + self.error: None | str = data["error"] self.trace: str | None = data.get("trace") self.path: str = data["path"] diff --git a/wavelink/types/response.py b/wavelink/types/response.py index 3b7ed305..0265aad5 100644 --- a/wavelink/types/response.py +++ b/wavelink/types/response.py @@ -35,7 +35,7 @@ class ErrorResponse(TypedDict): timestamp: int status: int - error: str + error: None | str trace: NotRequired[str] message: str path: str