From 6bbc6777087dc29bec7e0d0d1815db8e2669d87c Mon Sep 17 00:00:00 2001 From: Snipy7374 <100313469+Snipy7374@users.noreply.github.com> Date: Mon, 30 Jun 2025 09:19:33 +0200 Subject: [PATCH 1/3] add more voice disconnect reasons --- disnake/errors.py | 2 ++ 1 file changed, 2 insertions(+) diff --git a/disnake/errors.py b/disnake/errors.py index 410a3d5717..7c5400dabe 100644 --- a/disnake/errors.py +++ b/disnake/errors.py @@ -253,6 +253,8 @@ class ConnectionClosed(ClientException): 4015: "Voice server crashed", 4016: "Unknown encryption mode", 4020: "Bad request - you sent a malformed request", + 4021: "Disconnected: Rate Limited", + 4022: "Disconnected: Call Terminated (channel deleted, voice server changed, etc...)", } def __init__( From e4bec927c90d1a275c3cece19442c37b2ab451f9 Mon Sep 17 00:00:00 2001 From: Snipy7374 <100313469+Snipy7374@users.noreply.github.com> Date: Tue, 8 Jul 2025 10:34:47 +0200 Subject: [PATCH 2/3] Update disnake/errors.py Co-authored-by: vi <8530778+shiftinv@users.noreply.github.com> Signed-off-by: Snipy7374 <100313469+Snipy7374@users.noreply.github.com> --- disnake/errors.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/disnake/errors.py b/disnake/errors.py index 7c5400dabe..d3ccf35366 100644 --- a/disnake/errors.py +++ b/disnake/errors.py @@ -254,7 +254,7 @@ class ConnectionClosed(ClientException): 4016: "Unknown encryption mode", 4020: "Bad request - you sent a malformed request", 4021: "Disconnected: Rate Limited", - 4022: "Disconnected: Call Terminated (channel deleted, voice server changed, etc...)", + 4022: "Disconnected: Call Terminated (channel deleted, voice server changed, etc.)", } def __init__( From d601dfbeb1956534525633751f1a722d96707cb7 Mon Sep 17 00:00:00 2001 From: Snipy7374 <100313469+Snipy7374@users.noreply.github.com> Date: Tue, 8 Jul 2025 10:36:31 +0200 Subject: [PATCH 3/3] update 4014 voice disconnect reason --- disnake/errors.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/disnake/errors.py b/disnake/errors.py index 7c5400dabe..5d1ee9a932 100644 --- a/disnake/errors.py +++ b/disnake/errors.py @@ -249,7 +249,7 @@ class ConnectionClosed(ClientException): 4006: "Session no longer valid", 4011: "Server not found", 4012: "Unknown protocol", - 4014: "Disconnected, channel was deleted, you were kicked, voice server changed, or the main gateway session was dropped.", + 4014: "Disconnected (you were kicked, the main gateway session was dropped, etc.)", 4015: "Voice server crashed", 4016: "Unknown encryption mode", 4020: "Bad request - you sent a malformed request",