Skip to content

Commit 9854fef

Browse files
committed
fix: resolve clippy redundant_closure and expand env vars in socket field
CI sets RUSTFLAGS=-D warnings which promotes redundant_closure to an error. Also apply substitute_env_vars to the socket field so configs like socket: "$ENVOY_SOCK" resolve correctly, matching how uri and headers are already handled.
1 parent b884cd1 commit 9854fef

2 files changed

Lines changed: 2 additions & 2 deletions

File tree

crates/goose/src/agents/extension_manager.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -729,7 +729,7 @@ impl ExtensionManager {
729729
self.client_name.clone(),
730730
capability,
731731
&effective_working_dir,
732-
socket.as_deref(),
732+
socket.as_ref().map(|s| substitute_env_vars(s, &all_envs)).as_deref(),
733733
)
734734
.await?
735735
}

crates/goose/src/agents/unix_socket_http_client.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -85,7 +85,7 @@ async fn connect_unix(socket_path: &str) -> Result<UnixStream, std::io::Error> {
8585
Ok::<_, std::io::Error>(stream)
8686
})
8787
.await
88-
.map_err(|e| std::io::Error::other(e))??;
88+
.map_err(std::io::Error::other)??;
8989
return UnixStream::from_std(std_stream);
9090
}
9191

0 commit comments

Comments
 (0)