Skip to content

Commit 17ba1b7

Browse files
committed
fix(shell_executor.py): correct syntax error in token list by adding a comma between ";" and "&&" to ensure proper parsing of shell operators
1 parent 30c16ce commit 17ba1b7

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/mcp_shell_server/shell_executor.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -269,7 +269,7 @@ def _validate_pipeline(self, commands: List[str]) -> None:
269269
raise ValueError("Empty command before pipe operator")
270270
self._validate_command(current_cmd)
271271
current_cmd = []
272-
elif token in [";" "&&", "||"]:
272+
elif token in [";" , "&&", "||"]:
273273
raise ValueError(f"Unexpected shell operator in pipeline: {token}")
274274
else:
275275
current_cmd.append(token)

0 commit comments

Comments
 (0)