Your lightweight open-source personal agent.
Python agent-frameworkai-agentai-agentschatbotchatopsdiscord-botllm-agentsllmslocal-llmmcpmodel-context-protocolmulti-agentopenai-compatibleopenclawpersonal-ai-assistantpythonself-hostedtelegram-bot-ai-assistantwebuiworkflow-automation
fix(exec): use empty default and os.pathsep for cross-platform
aiguozhi1234567be278517e87
diff --git a/nanobot/agent/tools/shell.py b/nanobot/agent/tools/shell.pyindex c11fa2d92..c3810b2d1 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 = timeoutself.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_appendtry:process = await asyncio.create_subprocess_shell(diff --git a/nanobot/config/schema.py b/nanobot/config/schema.pyindex dd856fea7..4543ae0bc 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):