myagent-ai 1.16.4 → 1.16.5
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/package.json +1 -1
- package/skills/chromedev_mcp.py +5 -3
package/package.json
CHANGED
package/skills/chromedev_mcp.py
CHANGED
|
@@ -124,16 +124,18 @@ class MCPClient:
|
|
|
124
124
|
if self._slim:
|
|
125
125
|
args.append("--slim")
|
|
126
126
|
|
|
127
|
-
# [v1.16.
|
|
127
|
+
# [v1.16.4] 自动检测可用的浏览器,通过 --executablePath 传递给 MCP
|
|
128
128
|
browser_path = self._detect_browser()
|
|
129
129
|
env = {**os.environ, "NO_COLOR": "1"}
|
|
130
130
|
if browser_path:
|
|
131
|
-
|
|
132
|
-
env["CHROME_PATH"] = browser_path
|
|
131
|
+
args.extend(["--executablePath", browser_path])
|
|
133
132
|
logger.info(f"使用浏览器: {browser_path}")
|
|
134
133
|
else:
|
|
135
134
|
logger.warning("未找到 Chrome/Chromium 浏览器,尝试使用默认路径")
|
|
136
135
|
|
|
136
|
+
# 容器/Termux 环境需要 --no-sandbox
|
|
137
|
+
args.extend(["--chromeArg", "--no-sandbox", "--chromeArg", "--disable-setuid-sandbox"])
|
|
138
|
+
|
|
137
139
|
logger.info(f"启动 chrome-devtools-mcp: {' '.join(args)}")
|
|
138
140
|
|
|
139
141
|
try:
|