doer-agent 0.1.2 → 0.1.3
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/dist/agent.js +14 -2
- package/dist/playwright-mcp-call.js +8 -0
- package/package.json +1 -1
package/dist/agent.js
CHANGED
|
@@ -178,11 +178,23 @@ function resolvePlaywrightMcpProxyPath() {
|
|
|
178
178
|
return "";
|
|
179
179
|
}
|
|
180
180
|
const PLAYWRIGHT_MCP_PROXY_LAUNCHER_PATH = path.join(AGENT_PROJECT_DIR, "runtime/bin/playwright-mcp-proxy-launcher.sh");
|
|
181
|
+
function resolvePlaywrightMcpDaemonSocketPath(stateDir) {
|
|
182
|
+
if (process.platform === "win32") {
|
|
183
|
+
const suffix = stateDir
|
|
184
|
+
.toLowerCase()
|
|
185
|
+
.replace(/[^a-z0-9]+/g, "-")
|
|
186
|
+
.replace(/^-+|-+$/g, "")
|
|
187
|
+
.slice(-48) || "default";
|
|
188
|
+
return `\\\\.\\pipe\\doer-playwright-mcp-${suffix}`;
|
|
189
|
+
}
|
|
190
|
+
return path.join(stateDir, "playwright-mcp-daemon", "playwright-mcp.sock");
|
|
191
|
+
}
|
|
181
192
|
function resolvePlaywrightMcpDaemonStatePaths() {
|
|
182
|
-
const
|
|
193
|
+
const stateDir = resolveAgentStateDir();
|
|
194
|
+
const daemonDir = path.join(stateDir, "playwright-mcp-daemon");
|
|
183
195
|
return {
|
|
184
196
|
daemonDir,
|
|
185
|
-
socketPath:
|
|
197
|
+
socketPath: resolvePlaywrightMcpDaemonSocketPath(stateDir),
|
|
186
198
|
pidPath: path.join(daemonDir, "daemon.pid"),
|
|
187
199
|
metaPath: path.join(daemonDir, "daemon-meta.json"),
|
|
188
200
|
};
|
|
@@ -38,6 +38,14 @@ function resolveSocketPath() {
|
|
|
38
38
|
return explicit;
|
|
39
39
|
}
|
|
40
40
|
const stateDir = (process.env.DOER_AGENT_STATE_DIR || "").trim() || path.join(homedir(), ".doer-agent");
|
|
41
|
+
if (process.platform === "win32") {
|
|
42
|
+
const suffix = stateDir
|
|
43
|
+
.toLowerCase()
|
|
44
|
+
.replace(/[^a-z0-9]+/g, "-")
|
|
45
|
+
.replace(/^-+|-+$/g, "")
|
|
46
|
+
.slice(-48) || "default";
|
|
47
|
+
return `\\\\.\\pipe\\doer-playwright-mcp-${suffix}`;
|
|
48
|
+
}
|
|
41
49
|
return path.join(stateDir, "playwright-mcp-daemon", "playwright-mcp.sock");
|
|
42
50
|
}
|
|
43
51
|
function decodeToolArgs(argsBase64) {
|