diff --git a/nanobot/agent/tools/shell.py b/nanobot/agent/tools/shell.py index c11fa2d..c3810b2 100644 --- a/nanobot/agent/tools/shell.py +++ b/nanobot/agent/tools/shell.py @@ -19,7 +19,7 @@ class ExecTool(Tool): deny_patterns: list[str] | None = None, allow_patterns: list[str] | None = None, restrict_to_workspace: bool = False, - path_append: str = "/usr/sbin:/usr/local/sbin", + path_append: str = "", ): self.timeout = timeout self.working_dir = working_dir @@ -71,7 +71,7 @@ class ExecTool(Tool): env = os.environ.copy() if self.path_append: - env["PATH"] = env.get("PATH", "") + ":" + self.path_append + env["PATH"] = env.get("PATH", "") + os.pathsep + self.path_append try: process = await asyncio.create_subprocess_shell( diff --git a/nanobot/config/schema.py b/nanobot/config/schema.py index dd856fe..4543ae0 100644 --- a/nanobot/config/schema.py +++ b/nanobot/config/schema.py @@ -252,7 +252,7 @@ class ExecToolConfig(Base): """Shell exec tool configuration.""" timeout: int = 60 - path_append: str = "/usr/sbin:/usr/local/sbin" + path_append: str = "" class MCPServerConfig(Base):