Repository: serenity-rs/serenity (language: rust)

Issue:
Lower log level for unexpected WS disconnects
Currently this is at warn, causing spam for larger bots where WS disconnects are expected. This should be lowered to `info` and only `warn` or `error` if a reconnection fails entirely.

![image](https://github.com/user-attachments/assets/4bd07dfe-63c0-4f12-b6fd-41ede81ea1c0)



Discussion / hints:

Fix patch:
diff --git a/src/gateway/shard.rs b/src/gateway/shard.rs
index 4e6f7f29402..19ab0942461 100644
--- a/src/gateway/shard.rs
+++ b/src/gateway/shard.rs
@@ -482,7 +482,7 @@ impl Shard {
                 self.handle_gateway_closed(data.as_ref())
             },
             Err(Error::Tungstenite(why)) => {
-                warn!("[{:?}] Websocket error: {:?}", self.shard_info, why);
+                info!("[{:?}] Websocket error: {:?}", self.shard_info, why);
                 info!("[{:?}] Will attempt to auto-reconnect", self.shard_info);
 
                 Ok(Some(ShardAction::Reconnect(self.reconnection_type())))


Test patch: