devin-search-mcp 1.0.3 → 1.0.4
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/bin/devin-search-mcp.mjs +1 -1
- package/package.json +1 -1
- package/src/detector.mjs +4 -2
- package/src/fetch.mjs +5 -1
- package/src/search.mjs +1 -1
package/bin/devin-search-mcp.mjs
CHANGED
package/package.json
CHANGED
package/src/detector.mjs
CHANGED
|
@@ -140,19 +140,21 @@ export function inspectDevinStatus() {
|
|
|
140
140
|
authStatusText = execFileSync(executable, ["auth", "status"], {
|
|
141
141
|
encoding: "utf-8",
|
|
142
142
|
stdio: ["pipe", "pipe", "pipe"],
|
|
143
|
-
timeout:
|
|
143
|
+
timeout: 15000,
|
|
144
144
|
}).trim();
|
|
145
145
|
} catch (err) {
|
|
146
146
|
authStatusText = err.stdout || err.message;
|
|
147
147
|
}
|
|
148
148
|
}
|
|
149
149
|
|
|
150
|
+
const isLoggedIn = authStatusText.includes("Logged in") || hasToken;
|
|
151
|
+
|
|
150
152
|
return {
|
|
151
153
|
executable,
|
|
152
154
|
credentialsPath,
|
|
153
155
|
hasToken,
|
|
154
156
|
tokenSnippet,
|
|
155
|
-
isLoggedIn
|
|
157
|
+
isLoggedIn,
|
|
156
158
|
statusSummary: authStatusText,
|
|
157
159
|
};
|
|
158
160
|
}
|
package/src/fetch.mjs
CHANGED
|
@@ -14,7 +14,11 @@ import { searchCache } from "./cache.mjs";
|
|
|
14
14
|
* @param {"markdown"|"text"|"summary"} [options.extractMode="markdown"] - 提取格式
|
|
15
15
|
* @param {number} [options.timeoutMs=35000] - 超时毫秒数
|
|
16
16
|
*/
|
|
17
|
-
export async function executeWebFetch({
|
|
17
|
+
export async function executeWebFetch({
|
|
18
|
+
url,
|
|
19
|
+
extractMode = "markdown",
|
|
20
|
+
timeoutMs = parseInt(process.env.DEVIN_TIMEOUT_MS || "60000", 10),
|
|
21
|
+
}) {
|
|
18
22
|
if (!url || typeof url !== "string" || !/^https?:\/\//i.test(url)) {
|
|
19
23
|
throw new Error("请提供有效的 HTTP/HTTPS 网页 URL");
|
|
20
24
|
}
|
package/src/search.mjs
CHANGED