@sideboard-ai/core 0.1.147 → 0.1.149
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/agents/cursor-runner.cjs +45 -10
- package/dist/agents/cursor-runner.js +46 -11
- package/dist/{agents-YVETHB2R.js → agents-HSVQ2Z6Y.js} +4 -4
- package/dist/{agents-N3KMRQUZ.js → agents-V4MTDWXS.js} +3 -3
- package/dist/{chunk-JHZ6HGRI.js → chunk-3QRGCKYL.js} +1 -1
- package/dist/{chunk-SXPTL222.js → chunk-EGDRPA4B.js} +1 -1
- package/dist/{chunk-ZZBN2MR7.js → chunk-JDYKQ6OI.js} +12 -12
- package/dist/{chunk-WT5HSFOU.js → chunk-LAFA56WD.js} +4 -1
- package/dist/{chunk-KNE3FZ46.js → chunk-N3VNOFXQ.js} +1 -1
- package/dist/{chunk-WWH4NNBH.js → chunk-PTI5H3RK.js} +3 -3
- package/dist/{chunk-4RYRNJPN.js → chunk-Q5DHVMXB.js} +6 -3
- package/dist/{chunk-JW436RTA.js → chunk-Q62SDB53.js} +1 -1
- package/dist/{chunk-IHSR7EVK.js → chunk-R4JP32P5.js} +1 -1
- package/dist/{chunk-KZG47SZP.js → chunk-TZWO7J4W.js} +11 -11
- package/dist/{chunk-67K3FRKR.js → chunk-ZVYLEF72.js} +1 -1
- package/dist/{coordinator-prompt-2EOR35TP.js → coordinator-prompt-5GXGBGEZ.js} +1 -1
- package/dist/{coordinator-prompt-6EPVHVGJ.js → coordinator-prompt-ZWBMAIWA.js} +1 -1
- package/dist/{global-workspace-PANZGRUS.js → global-workspace-2SIPM4PW.js} +2 -2
- package/dist/{global-workspace-EZVQPMWT.js → global-workspace-OJRXWXEA.js} +2 -2
- package/dist/index.cjs +151 -7
- package/dist/index.d.cts +50 -1
- package/dist/index.d.ts +50 -1
- package/dist/index.js +151 -11
- package/dist/mcp/run-stdio.cjs +149 -7
- package/dist/mcp/run-stdio.js +149 -10
- package/dist/{orchestrator-T35BJZWY.js → orchestrator-6TXQWBXN.js} +5 -5
- package/dist/{orchestrator-KWV2PPML.js → orchestrator-Z2O5OVJA.js} +6 -6
- package/dist/{workspaces-ZJATBC4A.js → workspaces-3NUUZTQK.js} +3 -3
- package/dist/{workspaces-DWERPUQJ.js → workspaces-UUJNOO4T.js} +3 -3
- package/package.json +1 -1
|
@@ -212,6 +212,36 @@ function cursorSessionRecoveryMessage(err, agentId) {
|
|
|
212
212
|
}
|
|
213
213
|
return `Cursor session is unresumable (${detail}) \u2014 starting a new session`;
|
|
214
214
|
}
|
|
215
|
+
function isRetryableCursorTransportError(err) {
|
|
216
|
+
if (looksLikeNonRetryableCursorFailure(cursorErrorMessage(err))) return false;
|
|
217
|
+
if (err && typeof err === "object" && "isRetryable" in err && err.isRetryable === true) {
|
|
218
|
+
return true;
|
|
219
|
+
}
|
|
220
|
+
return /network request failed/i.test(cursorErrorMessage(err));
|
|
221
|
+
}
|
|
222
|
+
function looksLikeNonRetryableCursorFailure(message) {
|
|
223
|
+
const lower = message.toLowerCase();
|
|
224
|
+
return /invalid (?:user )?api key|not logged in|not authenticated|unauthorized|credit balance|out of credits|insufficient.?quota/.test(
|
|
225
|
+
lower
|
|
226
|
+
);
|
|
227
|
+
}
|
|
228
|
+
function cursorRetryableTransportMessage(err) {
|
|
229
|
+
const detail = cursorErrorMessage(err) || "network error";
|
|
230
|
+
return `Cursor hit a retryable error (${detail}) \u2014 retrying once`;
|
|
231
|
+
}
|
|
232
|
+
var CURSOR_RETRYABLE_TRANSPORT_DELAY_MS = 1500;
|
|
233
|
+
async function retryOnceOnRetryableCursorError(fn, onRetry, delayMs = CURSOR_RETRYABLE_TRANSPORT_DELAY_MS) {
|
|
234
|
+
try {
|
|
235
|
+
return await fn();
|
|
236
|
+
} catch (err) {
|
|
237
|
+
if (!isRetryableCursorTransportError(err)) throw err;
|
|
238
|
+
onRetry?.(err);
|
|
239
|
+
if (delayMs > 0) {
|
|
240
|
+
await new Promise((resolve) => setTimeout(resolve, delayMs));
|
|
241
|
+
}
|
|
242
|
+
return fn();
|
|
243
|
+
}
|
|
244
|
+
}
|
|
215
245
|
function cursorSendOptions(mcpServers) {
|
|
216
246
|
const opts = { local: { force: true } };
|
|
217
247
|
if (mcpServers && typeof mcpServers === "object" && Object.keys(mcpServers).length > 0) {
|
|
@@ -746,18 +776,23 @@ async function main() {
|
|
|
746
776
|
name: "Sideboard",
|
|
747
777
|
...mcpServers ? { mcpServers } : {}
|
|
748
778
|
};
|
|
779
|
+
const retryTransport = (fn) => retryOnceOnRetryableCursorError(fn, (err) => {
|
|
780
|
+
emit({ type: "stderr", data: cursorRetryableTransportMessage(err) });
|
|
781
|
+
});
|
|
749
782
|
async function createAgent() {
|
|
750
|
-
return import_sdk.Agent.create(createOpts);
|
|
783
|
+
return retryTransport(() => import_sdk.Agent.create(createOpts));
|
|
751
784
|
}
|
|
752
785
|
async function openAgent() {
|
|
753
786
|
try {
|
|
754
|
-
return req.agentId ? await
|
|
755
|
-
|
|
756
|
-
|
|
757
|
-
|
|
758
|
-
|
|
759
|
-
|
|
760
|
-
|
|
787
|
+
return req.agentId ? await retryTransport(
|
|
788
|
+
() => import_sdk.Agent.resume(req.agentId, {
|
|
789
|
+
apiKey,
|
|
790
|
+
model,
|
|
791
|
+
mode,
|
|
792
|
+
local,
|
|
793
|
+
...mcpServers ? { mcpServers } : {}
|
|
794
|
+
})
|
|
795
|
+
) : await createAgent();
|
|
761
796
|
} catch (err) {
|
|
762
797
|
if (!isUnresumableCursorSession(err)) throw err;
|
|
763
798
|
emit({
|
|
@@ -773,7 +808,7 @@ async function main() {
|
|
|
773
808
|
...extra
|
|
774
809
|
};
|
|
775
810
|
try {
|
|
776
|
-
return await agent.send(req.prompt, sendOpts);
|
|
811
|
+
return await retryTransport(() => agent.send(req.prompt, sendOpts));
|
|
777
812
|
} catch (err) {
|
|
778
813
|
if (!isAgentBusyError(err)) throw err;
|
|
779
814
|
const n = await cancelStaleLocalRuns(agent.agentId, {
|
|
@@ -784,7 +819,7 @@ async function main() {
|
|
|
784
819
|
type: "stderr",
|
|
785
820
|
data: n > 0 ? `Cursor agent had ${n} stale active run(s) \u2014 cancelled and retrying` : "Cursor agent busy \u2014 retrying send"
|
|
786
821
|
});
|
|
787
|
-
return agent.send(req.prompt, sendOpts);
|
|
822
|
+
return retryTransport(() => agent.send(req.prompt, sendOpts));
|
|
788
823
|
}
|
|
789
824
|
}
|
|
790
825
|
let liveRun = null;
|
|
@@ -12,7 +12,7 @@ import {
|
|
|
12
12
|
ensureCursorRipgrepPath,
|
|
13
13
|
fetchCursorTurnCostUsd,
|
|
14
14
|
formatUnknownDetail
|
|
15
|
-
} from "../chunk-
|
|
15
|
+
} from "../chunk-LAFA56WD.js";
|
|
16
16
|
import {
|
|
17
17
|
dropNestedElectronEnvFromProcess
|
|
18
18
|
} from "../chunk-4TR3HZFT.js";
|
|
@@ -50,6 +50,36 @@ function cursorSessionRecoveryMessage(err, agentId) {
|
|
|
50
50
|
}
|
|
51
51
|
return `Cursor session is unresumable (${detail}) \u2014 starting a new session`;
|
|
52
52
|
}
|
|
53
|
+
function isRetryableCursorTransportError(err) {
|
|
54
|
+
if (looksLikeNonRetryableCursorFailure(cursorErrorMessage(err))) return false;
|
|
55
|
+
if (err && typeof err === "object" && "isRetryable" in err && err.isRetryable === true) {
|
|
56
|
+
return true;
|
|
57
|
+
}
|
|
58
|
+
return /network request failed/i.test(cursorErrorMessage(err));
|
|
59
|
+
}
|
|
60
|
+
function looksLikeNonRetryableCursorFailure(message) {
|
|
61
|
+
const lower = message.toLowerCase();
|
|
62
|
+
return /invalid (?:user )?api key|not logged in|not authenticated|unauthorized|credit balance|out of credits|insufficient.?quota/.test(
|
|
63
|
+
lower
|
|
64
|
+
);
|
|
65
|
+
}
|
|
66
|
+
function cursorRetryableTransportMessage(err) {
|
|
67
|
+
const detail = cursorErrorMessage(err) || "network error";
|
|
68
|
+
return `Cursor hit a retryable error (${detail}) \u2014 retrying once`;
|
|
69
|
+
}
|
|
70
|
+
var CURSOR_RETRYABLE_TRANSPORT_DELAY_MS = 1500;
|
|
71
|
+
async function retryOnceOnRetryableCursorError(fn, onRetry, delayMs = CURSOR_RETRYABLE_TRANSPORT_DELAY_MS) {
|
|
72
|
+
try {
|
|
73
|
+
return await fn();
|
|
74
|
+
} catch (err) {
|
|
75
|
+
if (!isRetryableCursorTransportError(err)) throw err;
|
|
76
|
+
onRetry?.(err);
|
|
77
|
+
if (delayMs > 0) {
|
|
78
|
+
await new Promise((resolve) => setTimeout(resolve, delayMs));
|
|
79
|
+
}
|
|
80
|
+
return fn();
|
|
81
|
+
}
|
|
82
|
+
}
|
|
53
83
|
function cursorSendOptions(mcpServers) {
|
|
54
84
|
const opts = { local: { force: true } };
|
|
55
85
|
if (mcpServers && typeof mcpServers === "object" && Object.keys(mcpServers).length > 0) {
|
|
@@ -190,18 +220,23 @@ async function main() {
|
|
|
190
220
|
name: "Sideboard",
|
|
191
221
|
...mcpServers ? { mcpServers } : {}
|
|
192
222
|
};
|
|
223
|
+
const retryTransport = (fn) => retryOnceOnRetryableCursorError(fn, (err) => {
|
|
224
|
+
emit({ type: "stderr", data: cursorRetryableTransportMessage(err) });
|
|
225
|
+
});
|
|
193
226
|
async function createAgent() {
|
|
194
|
-
return Agent.create(createOpts);
|
|
227
|
+
return retryTransport(() => Agent.create(createOpts));
|
|
195
228
|
}
|
|
196
229
|
async function openAgent() {
|
|
197
230
|
try {
|
|
198
|
-
return req.agentId ? await
|
|
199
|
-
|
|
200
|
-
|
|
201
|
-
|
|
202
|
-
|
|
203
|
-
|
|
204
|
-
|
|
231
|
+
return req.agentId ? await retryTransport(
|
|
232
|
+
() => Agent.resume(req.agentId, {
|
|
233
|
+
apiKey,
|
|
234
|
+
model,
|
|
235
|
+
mode,
|
|
236
|
+
local,
|
|
237
|
+
...mcpServers ? { mcpServers } : {}
|
|
238
|
+
})
|
|
239
|
+
) : await createAgent();
|
|
205
240
|
} catch (err) {
|
|
206
241
|
if (!isUnresumableCursorSession(err)) throw err;
|
|
207
242
|
emit({
|
|
@@ -217,7 +252,7 @@ async function main() {
|
|
|
217
252
|
...extra
|
|
218
253
|
};
|
|
219
254
|
try {
|
|
220
|
-
return await agent.send(req.prompt, sendOpts);
|
|
255
|
+
return await retryTransport(() => agent.send(req.prompt, sendOpts));
|
|
221
256
|
} catch (err) {
|
|
222
257
|
if (!isAgentBusyError(err)) throw err;
|
|
223
258
|
const n = await cancelStaleLocalRuns(agent.agentId, {
|
|
@@ -228,7 +263,7 @@ async function main() {
|
|
|
228
263
|
type: "stderr",
|
|
229
264
|
data: n > 0 ? `Cursor agent had ${n} stale active run(s) \u2014 cancelled and retrying` : "Cursor agent busy \u2014 retrying send"
|
|
230
265
|
});
|
|
231
|
-
return agent.send(req.prompt, sendOpts);
|
|
266
|
+
return retryTransport(() => agent.send(req.prompt, sendOpts));
|
|
232
267
|
}
|
|
233
268
|
}
|
|
234
269
|
let liveRun = null;
|
|
@@ -30,7 +30,7 @@ import {
|
|
|
30
30
|
resolveLoginCommand,
|
|
31
31
|
resolveQuotaFallbackAgent,
|
|
32
32
|
whichOnPath
|
|
33
|
-
} from "./chunk-
|
|
33
|
+
} from "./chunk-PTI5H3RK.js";
|
|
34
34
|
import "./chunk-KBWND62T.js";
|
|
35
35
|
import "./chunk-M267JPEA.js";
|
|
36
36
|
import {
|
|
@@ -38,15 +38,15 @@ import {
|
|
|
38
38
|
assertOrchestratorCapableAgent,
|
|
39
39
|
coerceOrchestratorAgent,
|
|
40
40
|
isOrchestratorCapableAgent
|
|
41
|
-
} from "./chunk-
|
|
42
|
-
import "./chunk-
|
|
41
|
+
} from "./chunk-R4JP32P5.js";
|
|
42
|
+
import "./chunk-EGDRPA4B.js";
|
|
43
43
|
import "./chunk-ELBYOGVA.js";
|
|
44
44
|
import {
|
|
45
45
|
cursorSdkMessageToEvents,
|
|
46
46
|
parseCursorRunnerLine,
|
|
47
47
|
preferredCursorCostCents,
|
|
48
48
|
turnCostUsdFromCursorUsage
|
|
49
|
-
} from "./chunk-
|
|
49
|
+
} from "./chunk-LAFA56WD.js";
|
|
50
50
|
import "./chunk-YP3CSOZ6.js";
|
|
51
51
|
import "./chunk-FKOIHGKV.js";
|
|
52
52
|
import "./chunk-I77RYPOH.js";
|
|
@@ -36,7 +36,7 @@ import {
|
|
|
36
36
|
resolveQuotaFallbackAgent,
|
|
37
37
|
turnCostUsdFromCursorUsage,
|
|
38
38
|
whichOnPath
|
|
39
|
-
} from "./chunk-
|
|
39
|
+
} from "./chunk-Q5DHVMXB.js";
|
|
40
40
|
import "./chunk-ED4UPEJX.js";
|
|
41
41
|
import "./chunk-S42XV45P.js";
|
|
42
42
|
import "./chunk-6GN5WPYZ.js";
|
|
@@ -45,8 +45,8 @@ import {
|
|
|
45
45
|
assertOrchestratorCapableAgent,
|
|
46
46
|
coerceOrchestratorAgent,
|
|
47
47
|
isOrchestratorCapableAgent
|
|
48
|
-
} from "./chunk-
|
|
49
|
-
import "./chunk-
|
|
48
|
+
} from "./chunk-N3VNOFXQ.js";
|
|
49
|
+
import "./chunk-ZVYLEF72.js";
|
|
50
50
|
import "./chunk-JTPDWTWJ.js";
|
|
51
51
|
import "./chunk-B3SJXYIJ.js";
|
|
52
52
|
import "./chunk-EUXOHTUK.js";
|
|
@@ -46,7 +46,7 @@ var COORDINATOR_TOOL_PLAYBOOK = [
|
|
|
46
46
|
"- list_workspaces \u2014 registered repos (path + github slug when known)",
|
|
47
47
|
"- list_board \u2014 Home Kanban of worktrees (New / Draft / Review / Merged; one card per checkout). Path to merge: no PR \u2192 draft PR \u2192 open PR \u2192 merged. Archive removes the card to Settings \u2192 History. Queued/running are activity on the card, not columns. Orchestration chats are not on the board. Filters: query, repoPath, kind, column, limit.",
|
|
48
48
|
"- list_branches / list_prs / list_issues \u2014 pass repoPath from list_workspaces (issues: Linear, AbleTime MCP, or GitHub Issues)",
|
|
49
|
-
"- linear_list_teams / linear_get_issue / linear_create_issue / linear_update_issue / linear_comment \u2014 Linear Account connection; call linear_list_teams for team key and workflow states; pass ENG-123 or uuid. If mutations fail with a scope error, Disconnect and Connect Linear in Account settings.",
|
|
49
|
+
"- linear_list_teams / linear_get_issue / linear_create_issue / linear_update_issue / linear_comment \u2014 Linear Account connection; call linear_list_teams for team key and workflow states; pass ENG-123 or uuid. linear_get_issue returns comments, relations, parent/children, and the rest of the issue metadata. If mutations fail with a scope error, Disconnect and Connect Linear in Account settings.",
|
|
50
50
|
"- abletime_orientation / abletime_list_projects / abletime_list_tasks / abletime_search_tasks / abletime_get_task / abletime_create_task / abletime_ensure_task \u2014 AbleTime Account personal access token (hosted MCP). Call orientation first. If work has no task yet, abletime_ensure_task creates one to track against (or create_thread from the default branch does that automatically when AbleTime is the preferred issue source).",
|
|
51
51
|
"- list_teams / slack_list_channels / slack_list_users / slack_search / slack_read / slack_post / slack_replies \u2014 Slack workspaces from Settings \u2192 Remote; pass team_id from list_teams",
|
|
52
52
|
"- Optional connectors (Vercel, Supabase, PostHog, Sentry) in Settings \u2192 Connectors inject tokens into worktree agent env when connected. Prefer official CLIs (`vercel`, `supabase`, `sentry-cli`) with those env vars. PostHog has no first-class CLI \u2014 use the HTTP API (`POSTHOG_PERSONAL_API_KEY`). If a CLI is missing, the user can Install CLI on that row (not auto-installed on Connect). Do not add vendor MCPs or ask the user to paste tokens again. Git (`gh`) stays Settings \u2192 Git; issue tracking stays Settings \u2192 Issues; Slack stays Settings \u2192 Remote (Sideboard MCP).",
|
|
@@ -18,13 +18,13 @@ import {
|
|
|
18
18
|
stripBrightsyNdjsonNoise,
|
|
19
19
|
sumUsageList,
|
|
20
20
|
toolDescription
|
|
21
|
-
} from "./chunk-
|
|
21
|
+
} from "./chunk-PTI5H3RK.js";
|
|
22
22
|
import {
|
|
23
23
|
addWorkspace,
|
|
24
24
|
ensureWorkspace,
|
|
25
25
|
removeWorkspace,
|
|
26
26
|
syncWorkspacesFromThreads
|
|
27
|
-
} from "./chunk-
|
|
27
|
+
} from "./chunk-3QRGCKYL.js";
|
|
28
28
|
import {
|
|
29
29
|
assertOrchestratorCapableAgent,
|
|
30
30
|
attachmentsFromWorktreePaths,
|
|
@@ -41,14 +41,14 @@ import {
|
|
|
41
41
|
persistPendingFileAttachments,
|
|
42
42
|
stageAbsolutePathsAsAttachments,
|
|
43
43
|
stageBuffersAsAttachments
|
|
44
|
-
} from "./chunk-
|
|
44
|
+
} from "./chunk-R4JP32P5.js";
|
|
45
45
|
import {
|
|
46
46
|
SLACK_REPLY_FORMATTING,
|
|
47
47
|
coordinatorSystemPrompt,
|
|
48
48
|
coordinatorTurnReminder,
|
|
49
49
|
enrichWorkspacesWithGithub,
|
|
50
50
|
ensureGlobalCoordinatorCwd
|
|
51
|
-
} from "./chunk-
|
|
51
|
+
} from "./chunk-EGDRPA4B.js";
|
|
52
52
|
import {
|
|
53
53
|
httpFetch
|
|
54
54
|
} from "./chunk-ELBYOGVA.js";
|
|
@@ -74,7 +74,7 @@ import {
|
|
|
74
74
|
shouldRetryFailedAgentTurn,
|
|
75
75
|
summarizeTurnStderr,
|
|
76
76
|
turnFailChatText
|
|
77
|
-
} from "./chunk-
|
|
77
|
+
} from "./chunk-LAFA56WD.js";
|
|
78
78
|
import {
|
|
79
79
|
releaseCaffeinateHoldForThread
|
|
80
80
|
} from "./chunk-DCOZABNT.js";
|
|
@@ -456,7 +456,7 @@ async function continueSourceThread(threadId, prompt) {
|
|
|
456
456
|
await continueOnReply(threadId, prompt);
|
|
457
457
|
return;
|
|
458
458
|
}
|
|
459
|
-
const { getOrchestrator: getOrchestrator2 } = await import("./orchestrator-
|
|
459
|
+
const { getOrchestrator: getOrchestrator2 } = await import("./orchestrator-Z2O5OVJA.js");
|
|
460
460
|
await getOrchestrator2().send(threadId, prompt);
|
|
461
461
|
} catch {
|
|
462
462
|
}
|
|
@@ -736,9 +736,9 @@ async function spawnAgentTurn(thread, input, onEvent) {
|
|
|
736
736
|
`Cannot spawn ${thread.agent}: thread ${thread.id} has no worktreePath`
|
|
737
737
|
);
|
|
738
738
|
}
|
|
739
|
-
const { isGlobalThread: isGlobalThread2 } = await import("./global-workspace-
|
|
739
|
+
const { isGlobalThread: isGlobalThread2 } = await import("./global-workspace-OJRXWXEA.js");
|
|
740
740
|
if (isGlobalThread2(thread)) {
|
|
741
|
-
const { ensureGlobalCoordinatorCwd: ensureGlobalCoordinatorCwd2 } = await import("./coordinator-prompt-
|
|
741
|
+
const { ensureGlobalCoordinatorCwd: ensureGlobalCoordinatorCwd2 } = await import("./coordinator-prompt-ZWBMAIWA.js");
|
|
742
742
|
ensureGlobalCoordinatorCwd2(
|
|
743
743
|
isOrchestratorThread(thread) ? { orchestratorThreadId: thread.id } : void 0
|
|
744
744
|
);
|
|
@@ -3073,7 +3073,7 @@ async function createThread(input, _onSetupLine) {
|
|
|
3073
3073
|
return readThread(thread.id) ?? thread;
|
|
3074
3074
|
}
|
|
3075
3075
|
async function listLinearIssues(agent, repoPath) {
|
|
3076
|
-
const { getAdapter: getAdapter2 } = await import("./agents-
|
|
3076
|
+
const { getAdapter: getAdapter2 } = await import("./agents-HSVQ2Z6Y.js");
|
|
3077
3077
|
await requireAgent(agent, { requireLinear: true });
|
|
3078
3078
|
const adapter = getAdapter2(agent);
|
|
3079
3079
|
if (!adapter.listLinearIssues) {
|
|
@@ -3480,7 +3480,7 @@ async function adoptThread(input) {
|
|
|
3480
3480
|
messages: input.messages ?? []
|
|
3481
3481
|
});
|
|
3482
3482
|
writeThread(thread);
|
|
3483
|
-
const { ensureWorkspace: ensureWorkspace2 } = await import("./workspaces-
|
|
3483
|
+
const { ensureWorkspace: ensureWorkspace2 } = await import("./workspaces-3NUUZTQK.js");
|
|
3484
3484
|
await ensureWorkspace2(repoPath);
|
|
3485
3485
|
return thread;
|
|
3486
3486
|
}
|
|
@@ -5928,7 +5928,7 @@ function formatScheduledPrompt(name, prompt) {
|
|
|
5928
5928
|
${prompt}`;
|
|
5929
5929
|
}
|
|
5930
5930
|
async function defaultDeps() {
|
|
5931
|
-
const { getOrchestrator: getOrchestrator2, startOrchestration: startOrchestration2 } = await import("./orchestrator-
|
|
5931
|
+
const { getOrchestrator: getOrchestrator2, startOrchestration: startOrchestration2 } = await import("./orchestrator-Z2O5OVJA.js");
|
|
5932
5932
|
const orch = getOrchestrator2();
|
|
5933
5933
|
return {
|
|
5934
5934
|
findThread: (id) => findThreadByRef(id),
|
|
@@ -7864,7 +7864,7 @@ var Orchestrator = class {
|
|
|
7864
7864
|
this.emit({ type: "status_changed", threadId: archived.id, status: "archived" });
|
|
7865
7865
|
if (thread.repoPath && !isGlobalRepoPath(thread.repoPath)) {
|
|
7866
7866
|
try {
|
|
7867
|
-
const { ensureWorkspace: ensureWorkspace2 } = await import("./workspaces-
|
|
7867
|
+
const { ensureWorkspace: ensureWorkspace2 } = await import("./workspaces-3NUUZTQK.js");
|
|
7868
7868
|
await ensureWorkspace2(thread.repoPath);
|
|
7869
7869
|
} catch {
|
|
7870
7870
|
}
|
|
@@ -139,7 +139,7 @@ function looksLikeRetryableRunnerCrash(text) {
|
|
|
139
139
|
const lower = text.trim().toLowerCase();
|
|
140
140
|
if (/cannot find (?:package|module)|err_module_not_found/.test(lower)) return false;
|
|
141
141
|
if (!lower) return true;
|
|
142
|
-
return /uv_run|spineventloopinternal|libuv|homebrew node \+ shared libuv|cursor runner crashed in node|hascustomhostobject|electroninitializeicuandstartnode|nested chromium|truncated crash dump|connection stalled|sig(?:segv|abrt|ill)|segmentation fault|illegal instruction|fatal error/.test(
|
|
142
|
+
return /uv_run|spineventloopinternal|libuv|homebrew node \+ shared libuv|cursor runner crashed in node|hascustomhostobject|electroninitializeicuandstartnode|nested chromium|truncated crash dump|connection stalled|network request failed|cursor startup failed:.+\(retryable\)|sig(?:segv|abrt|ill)|segmentation fault|illegal instruction|fatal error/.test(
|
|
143
143
|
lower
|
|
144
144
|
);
|
|
145
145
|
}
|
|
@@ -207,6 +207,9 @@ function humanizeAgentFailDetail(detail) {
|
|
|
207
207
|
if (/connection stalled/.test(lower)) {
|
|
208
208
|
return /retry the turn/i.test(raw) ? raw : `${raw} \u2014 retry the turn (Sideboard will start a fresh Cursor session).`;
|
|
209
209
|
}
|
|
210
|
+
if (/network request failed|cursor startup failed:.+\(retryable\)/.test(lower)) {
|
|
211
|
+
return /retry the turn/i.test(raw) ? raw : `${raw} \u2014 retry the turn (a transient Cursor SDK network error).`;
|
|
212
|
+
}
|
|
210
213
|
return raw;
|
|
211
214
|
}
|
|
212
215
|
function turnFailChatText(opts) {
|
|
@@ -9,7 +9,7 @@ import {
|
|
|
9
9
|
} from "./chunk-M267JPEA.js";
|
|
10
10
|
import {
|
|
11
11
|
isOrchestratorThread
|
|
12
|
-
} from "./chunk-
|
|
12
|
+
} from "./chunk-R4JP32P5.js";
|
|
13
13
|
import {
|
|
14
14
|
applyAgentRunnerHeapEnv,
|
|
15
15
|
applyNodeLaunch,
|
|
@@ -22,7 +22,7 @@ import {
|
|
|
22
22
|
packagedMcpStdioPath,
|
|
23
23
|
parseCursorRunnerLine,
|
|
24
24
|
resolveNodeLaunch
|
|
25
|
-
} from "./chunk-
|
|
25
|
+
} from "./chunk-LAFA56WD.js";
|
|
26
26
|
import {
|
|
27
27
|
codexUnattendedGitConfigArgs,
|
|
28
28
|
mergeAgentGitAuthEnv,
|
|
@@ -1767,7 +1767,7 @@ var claudeAdapter = {
|
|
|
1767
1767
|
);
|
|
1768
1768
|
}
|
|
1769
1769
|
const mode = permissionMode(thread);
|
|
1770
|
-
const { isOrchestratorThread: isOrchestratorThread2 } = await import("./global-workspace-
|
|
1770
|
+
const { isOrchestratorThread: isOrchestratorThread2 } = await import("./global-workspace-OJRXWXEA.js");
|
|
1771
1771
|
const isOrchestrator = isOrchestratorThread2(thread);
|
|
1772
1772
|
const injectedServers = await buildInjectedMcpServers({
|
|
1773
1773
|
includeSideboard: true,
|
|
@@ -11,7 +11,7 @@ import {
|
|
|
11
11
|
} from "./chunk-S42XV45P.js";
|
|
12
12
|
import {
|
|
13
13
|
isOrchestratorThread
|
|
14
|
-
} from "./chunk-
|
|
14
|
+
} from "./chunk-N3VNOFXQ.js";
|
|
15
15
|
import {
|
|
16
16
|
codexUnattendedGitConfigArgs,
|
|
17
17
|
mergeAgentGitAuthEnv,
|
|
@@ -283,7 +283,7 @@ function looksLikeRetryableRunnerCrash(text) {
|
|
|
283
283
|
const lower = text.trim().toLowerCase();
|
|
284
284
|
if (/cannot find (?:package|module)|err_module_not_found/.test(lower)) return false;
|
|
285
285
|
if (!lower) return true;
|
|
286
|
-
return /uv_run|spineventloopinternal|libuv|homebrew node \+ shared libuv|cursor runner crashed in node|hascustomhostobject|electroninitializeicuandstartnode|nested chromium|truncated crash dump|connection stalled|sig(?:segv|abrt|ill)|segmentation fault|illegal instruction|fatal error/.test(
|
|
286
|
+
return /uv_run|spineventloopinternal|libuv|homebrew node \+ shared libuv|cursor runner crashed in node|hascustomhostobject|electroninitializeicuandstartnode|nested chromium|truncated crash dump|connection stalled|network request failed|cursor startup failed:.+\(retryable\)|sig(?:segv|abrt|ill)|segmentation fault|illegal instruction|fatal error/.test(
|
|
287
287
|
lower
|
|
288
288
|
);
|
|
289
289
|
}
|
|
@@ -351,6 +351,9 @@ function humanizeAgentFailDetail(detail) {
|
|
|
351
351
|
if (/connection stalled/.test(lower)) {
|
|
352
352
|
return /retry the turn/i.test(raw) ? raw : `${raw} \u2014 retry the turn (Sideboard will start a fresh Cursor session).`;
|
|
353
353
|
}
|
|
354
|
+
if (/network request failed|cursor startup failed:.+\(retryable\)/.test(lower)) {
|
|
355
|
+
return /retry the turn/i.test(raw) ? raw : `${raw} \u2014 retry the turn (a transient Cursor SDK network error).`;
|
|
356
|
+
}
|
|
354
357
|
return raw;
|
|
355
358
|
}
|
|
356
359
|
function turnFailChatText(opts) {
|
|
@@ -2085,7 +2088,7 @@ var claudeAdapter = {
|
|
|
2085
2088
|
);
|
|
2086
2089
|
}
|
|
2087
2090
|
const mode = permissionMode(thread);
|
|
2088
|
-
const { isOrchestratorThread: isOrchestratorThread2 } = await import("./global-workspace-
|
|
2091
|
+
const { isOrchestratorThread: isOrchestratorThread2 } = await import("./global-workspace-2SIPM4PW.js");
|
|
2089
2092
|
const isOrchestrator = isOrchestratorThread2(thread);
|
|
2090
2093
|
const injectedServers = await buildInjectedMcpServers({
|
|
2091
2094
|
includeSideboard: true,
|
|
@@ -32,13 +32,13 @@ import {
|
|
|
32
32
|
summarizeTurnStderr,
|
|
33
33
|
toolDescription,
|
|
34
34
|
turnFailChatText
|
|
35
|
-
} from "./chunk-
|
|
35
|
+
} from "./chunk-Q5DHVMXB.js";
|
|
36
36
|
import {
|
|
37
37
|
addWorkspace,
|
|
38
38
|
ensureWorkspace,
|
|
39
39
|
removeWorkspace,
|
|
40
40
|
syncWorkspacesFromThreads
|
|
41
|
-
} from "./chunk-
|
|
41
|
+
} from "./chunk-Q62SDB53.js";
|
|
42
42
|
import {
|
|
43
43
|
extractPresentedPlan,
|
|
44
44
|
readPlanFile,
|
|
@@ -63,14 +63,14 @@ import {
|
|
|
63
63
|
persistPendingFileAttachments,
|
|
64
64
|
stageAbsolutePathsAsAttachments,
|
|
65
65
|
stageBuffersAsAttachments
|
|
66
|
-
} from "./chunk-
|
|
66
|
+
} from "./chunk-N3VNOFXQ.js";
|
|
67
67
|
import {
|
|
68
68
|
SLACK_REPLY_FORMATTING,
|
|
69
69
|
coordinatorSystemPrompt,
|
|
70
70
|
coordinatorTurnReminder,
|
|
71
71
|
enrichWorkspacesWithGithub,
|
|
72
72
|
ensureGlobalCoordinatorCwd
|
|
73
|
-
} from "./chunk-
|
|
73
|
+
} from "./chunk-ZVYLEF72.js";
|
|
74
74
|
import {
|
|
75
75
|
addPrStackLayer,
|
|
76
76
|
allocateTeamName,
|
|
@@ -391,7 +391,7 @@ async function continueSourceThread(threadId, prompt) {
|
|
|
391
391
|
await continueOnReply(threadId, prompt);
|
|
392
392
|
return;
|
|
393
393
|
}
|
|
394
|
-
const { getOrchestrator: getOrchestrator2 } = await import("./orchestrator-
|
|
394
|
+
const { getOrchestrator: getOrchestrator2 } = await import("./orchestrator-6TXQWBXN.js");
|
|
395
395
|
await getOrchestrator2().send(threadId, prompt);
|
|
396
396
|
} catch {
|
|
397
397
|
}
|
|
@@ -732,9 +732,9 @@ async function spawnAgentTurn(thread, input, onEvent) {
|
|
|
732
732
|
`Cannot spawn ${thread.agent}: thread ${thread.id} has no worktreePath`
|
|
733
733
|
);
|
|
734
734
|
}
|
|
735
|
-
const { isGlobalThread: isGlobalThread2 } = await import("./global-workspace-
|
|
735
|
+
const { isGlobalThread: isGlobalThread2 } = await import("./global-workspace-2SIPM4PW.js");
|
|
736
736
|
if (isGlobalThread2(thread)) {
|
|
737
|
-
const { ensureGlobalCoordinatorCwd: ensureGlobalCoordinatorCwd2 } = await import("./coordinator-prompt-
|
|
737
|
+
const { ensureGlobalCoordinatorCwd: ensureGlobalCoordinatorCwd2 } = await import("./coordinator-prompt-5GXGBGEZ.js");
|
|
738
738
|
ensureGlobalCoordinatorCwd2(
|
|
739
739
|
isOrchestratorThread(thread) ? { orchestratorThreadId: thread.id } : void 0
|
|
740
740
|
);
|
|
@@ -3005,7 +3005,7 @@ async function createThread(input, _onSetupLine) {
|
|
|
3005
3005
|
return readThread(thread.id) ?? thread;
|
|
3006
3006
|
}
|
|
3007
3007
|
async function listLinearIssues(agent, repoPath) {
|
|
3008
|
-
const { getAdapter: getAdapter2 } = await import("./agents-
|
|
3008
|
+
const { getAdapter: getAdapter2 } = await import("./agents-V4MTDWXS.js");
|
|
3009
3009
|
await requireAgent(agent, { requireLinear: true });
|
|
3010
3010
|
const adapter = getAdapter2(agent);
|
|
3011
3011
|
if (!adapter.listLinearIssues) {
|
|
@@ -3412,7 +3412,7 @@ async function adoptThread(input) {
|
|
|
3412
3412
|
messages: input.messages ?? []
|
|
3413
3413
|
});
|
|
3414
3414
|
writeThread(thread);
|
|
3415
|
-
const { ensureWorkspace: ensureWorkspace2 } = await import("./workspaces-
|
|
3415
|
+
const { ensureWorkspace: ensureWorkspace2 } = await import("./workspaces-UUJNOO4T.js");
|
|
3416
3416
|
await ensureWorkspace2(repoPath);
|
|
3417
3417
|
return thread;
|
|
3418
3418
|
}
|
|
@@ -5611,7 +5611,7 @@ function formatScheduledPrompt(name, prompt) {
|
|
|
5611
5611
|
${prompt}`;
|
|
5612
5612
|
}
|
|
5613
5613
|
async function defaultDeps() {
|
|
5614
|
-
const { getOrchestrator: getOrchestrator2, startOrchestration: startOrchestration2 } = await import("./orchestrator-
|
|
5614
|
+
const { getOrchestrator: getOrchestrator2, startOrchestration: startOrchestration2 } = await import("./orchestrator-6TXQWBXN.js");
|
|
5615
5615
|
const orch = getOrchestrator2();
|
|
5616
5616
|
return {
|
|
5617
5617
|
findThread: (id) => findThreadByRef(id),
|
|
@@ -7547,7 +7547,7 @@ var Orchestrator = class {
|
|
|
7547
7547
|
this.emit({ type: "status_changed", threadId: archived.id, status: "archived" });
|
|
7548
7548
|
if (thread.repoPath && !isGlobalRepoPath(thread.repoPath)) {
|
|
7549
7549
|
try {
|
|
7550
|
-
const { ensureWorkspace: ensureWorkspace2 } = await import("./workspaces-
|
|
7550
|
+
const { ensureWorkspace: ensureWorkspace2 } = await import("./workspaces-UUJNOO4T.js");
|
|
7551
7551
|
await ensureWorkspace2(thread.repoPath);
|
|
7552
7552
|
} catch {
|
|
7553
7553
|
}
|
|
@@ -48,7 +48,7 @@ var COORDINATOR_TOOL_PLAYBOOK = [
|
|
|
48
48
|
"- list_workspaces \u2014 registered repos (path + github slug when known)",
|
|
49
49
|
"- list_board \u2014 Home Kanban of worktrees (New / Draft / Review / Merged; one card per checkout). Path to merge: no PR \u2192 draft PR \u2192 open PR \u2192 merged. Archive removes the card to Settings \u2192 History. Queued/running are activity on the card, not columns. Orchestration chats are not on the board. Filters: query, repoPath, kind, column, limit.",
|
|
50
50
|
"- list_branches / list_prs / list_issues \u2014 pass repoPath from list_workspaces (issues: Linear, AbleTime MCP, or GitHub Issues)",
|
|
51
|
-
"- linear_list_teams / linear_get_issue / linear_create_issue / linear_update_issue / linear_comment \u2014 Linear Account connection; call linear_list_teams for team key and workflow states; pass ENG-123 or uuid. If mutations fail with a scope error, Disconnect and Connect Linear in Account settings.",
|
|
51
|
+
"- linear_list_teams / linear_get_issue / linear_create_issue / linear_update_issue / linear_comment \u2014 Linear Account connection; call linear_list_teams for team key and workflow states; pass ENG-123 or uuid. linear_get_issue returns comments, relations, parent/children, and the rest of the issue metadata. If mutations fail with a scope error, Disconnect and Connect Linear in Account settings.",
|
|
52
52
|
"- abletime_orientation / abletime_list_projects / abletime_list_tasks / abletime_search_tasks / abletime_get_task / abletime_create_task / abletime_ensure_task \u2014 AbleTime Account personal access token (hosted MCP). Call orientation first. If work has no task yet, abletime_ensure_task creates one to track against (or create_thread from the default branch does that automatically when AbleTime is the preferred issue source).",
|
|
53
53
|
"- list_teams / slack_list_channels / slack_list_users / slack_search / slack_read / slack_post / slack_replies \u2014 Slack workspaces from Settings \u2192 Remote; pass team_id from list_teams",
|
|
54
54
|
"- Optional connectors (Vercel, Supabase, PostHog, Sentry) in Settings \u2192 Connectors inject tokens into worktree agent env when connected. Prefer official CLIs (`vercel`, `supabase`, `sentry-cli`) with those env vars. PostHog has no first-class CLI \u2014 use the HTTP API (`POSTHOG_PERSONAL_API_KEY`). If a CLI is missing, the user can Install CLI on that row (not auto-installed on Connect). Do not add vendor MCPs or ask the user to paste tokens again. Git (`gh`) stays Settings \u2192 Git; issue tracking stays Settings \u2192 Issues; Slack stays Settings \u2192 Remote (Sideboard MCP).",
|
|
@@ -17,8 +17,8 @@ import {
|
|
|
17
17
|
orchestratorSessionPoisonedByBuiltins,
|
|
18
18
|
slackCoordinatorSourceRef,
|
|
19
19
|
takenTeamSlugsForOrchestration
|
|
20
|
-
} from "./chunk-
|
|
21
|
-
import "./chunk-
|
|
20
|
+
} from "./chunk-N3VNOFXQ.js";
|
|
21
|
+
import "./chunk-ZVYLEF72.js";
|
|
22
22
|
import "./chunk-JTPDWTWJ.js";
|
|
23
23
|
import "./chunk-B3SJXYIJ.js";
|
|
24
24
|
import "./chunk-EUXOHTUK.js";
|
|
@@ -15,8 +15,8 @@ import {
|
|
|
15
15
|
orchestratorSessionPoisonedByBuiltins,
|
|
16
16
|
slackCoordinatorSourceRef,
|
|
17
17
|
takenTeamSlugsForOrchestration
|
|
18
|
-
} from "./chunk-
|
|
19
|
-
import "./chunk-
|
|
18
|
+
} from "./chunk-R4JP32P5.js";
|
|
19
|
+
import "./chunk-EGDRPA4B.js";
|
|
20
20
|
import "./chunk-YP3CSOZ6.js";
|
|
21
21
|
import "./chunk-FKOIHGKV.js";
|
|
22
22
|
import "./chunk-I77RYPOH.js";
|