Skip to content

Commit 2732fbf

Browse files
authored
Fix: child process spawned for mcp no inheriting env vars from parent (#287)
1 parent 00e50ce commit 2732fbf

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

crates/chat-cli/src/mcp_client/client.rs

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -180,7 +180,8 @@ impl Client<StdioTransport> {
180180
command
181181
.stdin(Stdio::piped())
182182
.stdout(Stdio::piped())
183-
.stderr(Stdio::piped());
183+
.stderr(Stdio::piped())
184+
.envs(std::env::vars());
184185

185186
#[cfg(not(windows))]
186187
command.process_group(0);

0 commit comments

Comments
 (0)