Skip to content

Commit

Permalink
CLI: show websocket connection failure details (#1592)
Browse files Browse the repository at this point in the history
For whatever reason the error detail wasn't surfaced while I was
debugging some TLS things.

This `.inspect_err()` gave me what I needed. Let's keep it in there.
  • Loading branch information
svix-onelson authored Dec 26, 2024
2 parents fd0a9c0 + c8980d8 commit dbc59e3
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions svix-cli/src/relay/mod.rs
Original file line number Diff line number Diff line change
Expand Up @@ -316,6 +316,7 @@ impl WsConnection {
let request = websocket_url.to_string().into_client_request()?;
let (stream, _resp) = connect_async(request)
.await
.inspect_err(|e| eprintln!("{e}"))
.context("failed to connect to websocket server")?;

Ok(Self { stream })
Expand Down

0 comments on commit dbc59e3

Please sign in to comment.