@geometra/mcp 1.65.7 → 1.65.8
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/action-timeouts.d.ts +8 -0
- package/dist/action-timeouts.js +8 -0
- package/dist/server.js +7 -2
- package/dist/session.js +5 -2
- package/package.json +2 -2
|
@@ -6,3 +6,11 @@
|
|
|
6
6
|
*/
|
|
7
7
|
export declare const LISTBOX_CORRELATED_RESPONSE_TIMEOUT_MS = 15000;
|
|
8
8
|
export declare const LISTBOX_ACK_GRACE_MS = 3000;
|
|
9
|
+
/**
|
|
10
|
+
* Semantic text fills can cross several Playwright operations before the
|
|
11
|
+
* proxy can acknowledge them, especially when a caller enables slowMo for a
|
|
12
|
+
* live form. Keep the correlated listener alive without extending the
|
|
13
|
+
* browser-side start deadline to the same boundary.
|
|
14
|
+
*/
|
|
15
|
+
export declare const TEXT_FIELD_CORRELATED_RESPONSE_TIMEOUT_MS = 15000;
|
|
16
|
+
export declare const TEXT_FIELD_ACK_GRACE_MS = 3000;
|
package/dist/action-timeouts.js
CHANGED
|
@@ -6,3 +6,11 @@
|
|
|
6
6
|
*/
|
|
7
7
|
export const LISTBOX_CORRELATED_RESPONSE_TIMEOUT_MS = 15_000;
|
|
8
8
|
export const LISTBOX_ACK_GRACE_MS = 3_000;
|
|
9
|
+
/**
|
|
10
|
+
* Semantic text fills can cross several Playwright operations before the
|
|
11
|
+
* proxy can acknowledge them, especially when a caller enables slowMo for a
|
|
12
|
+
* live form. Keep the correlated listener alive without extending the
|
|
13
|
+
* browser-side start deadline to the same boundary.
|
|
14
|
+
*/
|
|
15
|
+
export const TEXT_FIELD_CORRELATED_RESPONSE_TIMEOUT_MS = 15_000;
|
|
16
|
+
export const TEXT_FIELD_ACK_GRACE_MS = 3_000;
|
package/dist/server.js
CHANGED
|
@@ -2,7 +2,7 @@ import { createHash } from 'node:crypto';
|
|
|
2
2
|
import { performance } from 'node:perf_hooks';
|
|
3
3
|
import { McpServer } from '@modelcontextprotocol/sdk/server/mcp.js';
|
|
4
4
|
import { z } from 'zod';
|
|
5
|
-
import { LISTBOX_CORRELATED_RESPONSE_TIMEOUT_MS } from './action-timeouts.js';
|
|
5
|
+
import { LISTBOX_CORRELATED_RESPONSE_TIMEOUT_MS, TEXT_FIELD_CORRELATED_RESPONSE_TIMEOUT_MS, } from './action-timeouts.js';
|
|
6
6
|
import { formatConnectFailureMessage, isHttpUrl, normalizeConnectTarget } from './connect-utils.js';
|
|
7
7
|
import { REDACTED_STATE_URL, sanitizeUrlToOrigin } from './state-privacy.js';
|
|
8
8
|
import { SERVER_IMPLEMENTATION } from './version.js';
|
|
@@ -249,7 +249,12 @@ function timeoutCapFromDeadline(deadlineAt, reserveMs = HOST_SAFE_TIMEOUT_RESERV
|
|
|
249
249
|
function capTimeoutMs(timeoutMs, capMs, fallbackMs) {
|
|
250
250
|
return Math.max(MIN_ACTION_TIMEOUT_MS, Math.min(timeoutMs ?? fallbackMs, Math.max(MIN_ACTION_TIMEOUT_MS, Math.floor(capMs))));
|
|
251
251
|
}
|
|
252
|
-
function capFillFieldTimeout(field, capMs
|
|
252
|
+
function capFillFieldTimeout(field, capMs) {
|
|
253
|
+
const fallbackMs = field.kind === 'text'
|
|
254
|
+
? TEXT_FIELD_CORRELATED_RESPONSE_TIMEOUT_MS
|
|
255
|
+
: field.kind === 'file'
|
|
256
|
+
? 8_000
|
|
257
|
+
: 5_000;
|
|
253
258
|
return {
|
|
254
259
|
...field,
|
|
255
260
|
timeoutMs: capTimeoutMs(field.timeoutMs, capMs, fallbackMs),
|
package/dist/session.js
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { createHash, randomUUID } from 'node:crypto';
|
|
2
2
|
import { performance } from 'node:perf_hooks';
|
|
3
3
|
import WebSocket from 'ws';
|
|
4
|
-
import { LISTBOX_ACK_GRACE_MS, LISTBOX_CORRELATED_RESPONSE_TIMEOUT_MS, } from './action-timeouts.js';
|
|
4
|
+
import { LISTBOX_ACK_GRACE_MS, LISTBOX_CORRELATED_RESPONSE_TIMEOUT_MS, TEXT_FIELD_ACK_GRACE_MS, TEXT_FIELD_CORRELATED_RESPONSE_TIMEOUT_MS, } from './action-timeouts.js';
|
|
5
5
|
import { resolveStealthMode, spawnGeometraProxy, startEmbeddedGeometraProxy, } from './proxy-spawn.js';
|
|
6
6
|
import { completeSessionLifecycle, failSessionLifecycle, heartbeatSessionLifecycle, initializeSessionLifecycle, recordSessionSnapshot, } from './session-state.js';
|
|
7
7
|
import { REDACTED_STATE_URL, sanitizeUrlToOrigin } from './state-privacy.js';
|
|
@@ -246,6 +246,9 @@ function actionTimeoutFor(session, message, timeoutMs) {
|
|
|
246
246
|
if (message.type === 'listboxPick') {
|
|
247
247
|
return Math.max(MIN_PROXY_ACTION_TIMEOUT_MS, timeoutMs - LISTBOX_ACK_GRACE_MS);
|
|
248
248
|
}
|
|
249
|
+
if (message.type === 'setFieldText') {
|
|
250
|
+
return Math.max(MIN_PROXY_ACTION_TIMEOUT_MS, timeoutMs - TEXT_FIELD_ACK_GRACE_MS);
|
|
251
|
+
}
|
|
249
252
|
return timeoutMs;
|
|
250
253
|
}
|
|
251
254
|
function ambiguousOperationFor(session, fingerprint) {
|
|
@@ -2115,7 +2118,7 @@ export function sendFileUpload(session, paths, opts, timeoutMs) {
|
|
|
2115
2118
|
return sendAndWaitForUpdate(session, payload, timeoutMs);
|
|
2116
2119
|
}
|
|
2117
2120
|
/** Set a labeled text-like field (`input`, `textarea`, contenteditable, ARIA textbox) semantically. */
|
|
2118
|
-
export function sendFieldText(session, fieldLabel, value, opts, timeoutMs) {
|
|
2121
|
+
export function sendFieldText(session, fieldLabel, value, opts, timeoutMs = TEXT_FIELD_CORRELATED_RESPONSE_TIMEOUT_MS) {
|
|
2119
2122
|
const payload = {
|
|
2120
2123
|
type: 'setFieldText',
|
|
2121
2124
|
fieldLabel,
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@geometra/mcp",
|
|
3
|
-
"version": "1.65.
|
|
3
|
+
"version": "1.65.8",
|
|
4
4
|
"description": "MCP server for Geometra — interact with running Geometra apps via the geometry protocol, no browser needed",
|
|
5
5
|
"license": "MIT",
|
|
6
6
|
"type": "module",
|
|
@@ -32,7 +32,7 @@
|
|
|
32
32
|
"ui-testing"
|
|
33
33
|
],
|
|
34
34
|
"dependencies": {
|
|
35
|
-
"@geometra/proxy": "^1.65.
|
|
35
|
+
"@geometra/proxy": "^1.65.8",
|
|
36
36
|
"@modelcontextprotocol/sdk": "^1.12.1",
|
|
37
37
|
"@razroo/parallel-mcp": "^0.1.0",
|
|
38
38
|
"ws": "^8.21.0",
|