@mehmoodqureshi/chrome-mcp 0.7.0 → 0.7.1
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.
|
@@ -26,12 +26,11 @@ exports.appendHistory = appendHistory;
|
|
|
26
26
|
const node_fs_1 = require("node:fs");
|
|
27
27
|
const node_path_1 = require("node:path");
|
|
28
28
|
const config_1 = require("../config");
|
|
29
|
+
// `mcp/log` (not `mcp/server`) so this stays free of the server import cycle
|
|
30
|
+
// while still honouring `--log-level silent`.
|
|
31
|
+
const log_1 = require("../mcp/log");
|
|
29
32
|
const download_1 = require("../../shared/download");
|
|
30
33
|
const datadir_1 = require("./datadir");
|
|
31
|
-
/** stderr only (never stdout in stdio mode); local to avoid an import cycle with mcp/server. */
|
|
32
|
-
function logErr(message) {
|
|
33
|
-
process.stderr.write(`[chrome-mcp] ${message}\n`);
|
|
34
|
-
}
|
|
35
34
|
let active = null;
|
|
36
35
|
/** Monotonic counter so saved result/screenshot filenames sort in capture order. */
|
|
37
36
|
let seq = 0;
|
|
@@ -100,7 +99,7 @@ function saveResult(tool, ext, body) {
|
|
|
100
99
|
return path;
|
|
101
100
|
}
|
|
102
101
|
catch (err) {
|
|
103
|
-
logErr(`results save failed: ${err instanceof Error ? err.message : String(err)}`);
|
|
102
|
+
(0, log_1.logErr)(`results save failed: ${err instanceof Error ? err.message : String(err)}`);
|
|
104
103
|
return null;
|
|
105
104
|
}
|
|
106
105
|
}
|
|
@@ -119,7 +118,7 @@ function saveBinary(tool, ext, bytes) {
|
|
|
119
118
|
return path;
|
|
120
119
|
}
|
|
121
120
|
catch (err) {
|
|
122
|
-
logErr(`results save failed: ${err instanceof Error ? err.message : String(err)}`);
|
|
121
|
+
(0, log_1.logErr)(`results save failed: ${err instanceof Error ? err.message : String(err)}`);
|
|
123
122
|
return null;
|
|
124
123
|
}
|
|
125
124
|
}
|
|
@@ -134,7 +133,7 @@ function saveScreenshot(dataBase64) {
|
|
|
134
133
|
return path;
|
|
135
134
|
}
|
|
136
135
|
catch (err) {
|
|
137
|
-
logErr(`screenshot save failed: ${err instanceof Error ? err.message : String(err)}`);
|
|
136
|
+
(0, log_1.logErr)(`screenshot save failed: ${err instanceof Error ? err.message : String(err)}`);
|
|
138
137
|
return null;
|
|
139
138
|
}
|
|
140
139
|
}
|
|
@@ -176,7 +175,7 @@ function appendHistory(entry) {
|
|
|
176
175
|
(0, node_fs_1.appendFileSync)(w.historyPath, `${JSON.stringify(entry)}\n`, { mode: 0o600 });
|
|
177
176
|
}
|
|
178
177
|
catch (err) {
|
|
179
|
-
logErr(`history append failed: ${err instanceof Error ? err.message : String(err)}`);
|
|
178
|
+
(0, log_1.logErr)(`history append failed: ${err instanceof Error ? err.message : String(err)}`);
|
|
180
179
|
}
|
|
181
180
|
}
|
|
182
181
|
//# sourceMappingURL=workspace.js.map
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@mehmoodqureshi/chrome-mcp",
|
|
3
|
-
"version": "0.7.
|
|
3
|
+
"version": "0.7.1",
|
|
4
4
|
"description": "Drive your real Chrome browser over MCP — real logins, real cookies. A stdio MCP server (CLI) plus an MV3 extension, driving Chrome via chrome.scripting/chrome.tabs. Multi-tab batch automation, accessibility snapshots, deny-all security by default.",
|
|
5
5
|
"author": "Mehmood Ur Rehman Qureshi",
|
|
6
6
|
"license": "MIT",
|