Summary
As of March 2-3, 2026, Discord began enforcing the DAVE protocol (Discord Audio/Video End-to-End Encryption) for all non-stage voice calls. The bot can no longer join voice channels — Discord's voice gateway rejects the WebSocket connection with close code 4017.
Symptoms
- Bot briefly appears to join the voice channel on the Discord client side, then disconnects moments later
- All voice features are broken: soundboard, TTS, VOX
- The dashboard shows join attempts timing out
Error Logs
[Discord.NET] Connecting
[Discord.NET] null
System.Net.WebSockets.WebSocketException (0x80004005): WebSocket connection was closed
---> Discord.Net.WebSocketClosedException: The server sent close 4017: "E2EE/DAVE protocol required"
at Discord.Net.WebSockets.DefaultWebSocketClient.RunAsync(CancellationToken cancelToken)
at Discord.Audio.AudioClient.OnConnectingAsync()
...
[Discord.NET] Disconnecting
[Discord.NET] Disconnected
Error joining voice channel {channelId} in guild {guildId}
System.TimeoutException: The operation has timed out.
at Discord.WebSocket.SocketGuild.ConnectAudioAsync(...)
at DiscordBot.Bot.Services.AudioService.JoinChannelAsync(...) in AudioService.cs:line 96
Root Cause
- Discord enforcement: Discord now requires all voice clients to implement the DAVE protocol (E2EE for audio/video). Connections without DAVE support are rejected with close code
4017. See Discord's announcement.
- Current version: The bot uses
Discord.Net 3.19.0-beta.1, which does not include libdave/DAVE support.
- Fix available:
Discord.Net 3.19.0 (stable, released 2026-03-03) adds libdave support (PR #3241).
Affected Components
AudioService.JoinChannelAsync() — voice connection establishment
PlaybackService — all audio playback (soundboard, TTS, VOX)
AudioController — REST API endpoints for voice operations
VoiceAutoLeaveService — cannot function without active connections
- Docker image — may need updated native libraries for libdave
Fix
- Update
Discord.Net from 3.19.0-beta.1 → 3.19.0 in DiscordBot.Bot.csproj
- Verify libdave native dependencies are available in the Docker runtime image (may need additional system packages)
- Check if any API changes in the stable release require code updates
- Rebuild and redeploy the Docker image
References
Summary
As of March 2-3, 2026, Discord began enforcing the DAVE protocol (Discord Audio/Video End-to-End Encryption) for all non-stage voice calls. The bot can no longer join voice channels — Discord's voice gateway rejects the WebSocket connection with close code
4017.Symptoms
Error Logs
Root Cause
4017. See Discord's announcement.Discord.Net 3.19.0-beta.1, which does not include libdave/DAVE support.Discord.Net 3.19.0(stable, released 2026-03-03) adds libdave support (PR #3241).Affected Components
AudioService.JoinChannelAsync()— voice connection establishmentPlaybackService— all audio playback (soundboard, TTS, VOX)AudioController— REST API endpoints for voice operationsVoiceAutoLeaveService— cannot function without active connectionsFix
Discord.Netfrom3.19.0-beta.1→3.19.0inDiscordBot.Bot.csprojReferences