@sideboard-ai/core 0.1.189 → 0.1.190

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.
@@ -12,7 +12,7 @@ import {
12
12
  ensureCursorRipgrepPath,
13
13
  fetchCursorTurnCostUsd,
14
14
  formatUnknownDetail
15
- } from "../chunk-ZSFQLR7Y.js";
15
+ } from "../chunk-FY64F2ZQ.js";
16
16
  import {
17
17
  dropNestedElectronEnvFromProcess
18
18
  } from "../chunk-4TR3HZFT.js";
@@ -38,7 +38,7 @@ import {
38
38
  resolveQuotaFallbackAgent,
39
39
  turnCostUsdFromCursorUsage,
40
40
  whichOnPath
41
- } from "./chunk-QU663NPO.js";
41
+ } from "./chunk-GBWKMWUQ.js";
42
42
  import "./chunk-HVIEYTUK.js";
43
43
  import "./chunk-Y4MIXGPA.js";
44
44
  import "./chunk-VKQGAWHY.js";
@@ -32,7 +32,7 @@ import {
32
32
  resolveLoginCommand,
33
33
  resolveQuotaFallbackAgent,
34
34
  whichOnPath
35
- } from "./chunk-ISOCLQEX.js";
35
+ } from "./chunk-OLDZXO53.js";
36
36
  import "./chunk-VIODP5PT.js";
37
37
  import "./chunk-WXKXSZN4.js";
38
38
  import "./chunk-6K64FJDD.js";
@@ -44,7 +44,7 @@ import {
44
44
  parseCursorRunnerLine,
45
45
  preferredCursorCostCents,
46
46
  turnCostUsdFromCursorUsage
47
- } from "./chunk-ZSFQLR7Y.js";
47
+ } from "./chunk-FY64F2ZQ.js";
48
48
  import {
49
49
  ORCHESTRATOR_AGENT_KINDS,
50
50
  assertOrchestratorCapableAgent,
@@ -86,13 +86,21 @@ function looksLikeHugeToolResultDump(text) {
86
86
  if (t.length < 4e3) return false;
87
87
  return looksLikeMinifiedJsDump(t);
88
88
  }
89
+ function looksLikeJobWaitResult(rec) {
90
+ if (typeof rec.delta === "string") {
91
+ return typeof rec.status === "string" || typeof rec.id === "string" || typeof rec.stillRunning === "boolean";
92
+ }
93
+ if (typeof rec.stopped === "boolean") {
94
+ return typeof rec.id === "string" || typeof rec.status === "string";
95
+ }
96
+ return rec.started === true || rec.reason === "already-running";
97
+ }
89
98
  function clipJobWaitResultJson(content) {
90
99
  const trimmed = content.trim();
91
100
  if (!trimmed.startsWith("{")) return void 0;
92
101
  try {
93
102
  const rec = JSON.parse(trimmed);
94
- const isJob = typeof rec.stillRunning === "boolean" || typeof rec.stopped === "boolean" || typeof rec.delta === "string" && typeof rec.status === "string";
95
- if (!isJob) return void 0;
103
+ if (!looksLikeJobWaitResult(rec)) return void 0;
96
104
  if (typeof rec.delta === "string" && rec.delta.length > 3500) {
97
105
  rec.delta = `\u2026(truncated ${rec.delta.length} chars)
98
106
  ${rec.delta.slice(-3500)}`;
@@ -150,7 +158,7 @@ function looksLikeHomebrewLibuvCrash(text) {
150
158
  return /Cellar\/(?:libuv|node)|libuv\.\d+\.dylib/i.test(text);
151
159
  }
152
160
  var NESTED_ELECTRON_SUMMARY = "Cursor local agent crashed at Electron startup (nested Chromium / HasCustomHostObject)";
153
- var HOMEBREW_LIBUV_SUMMARY = "Cursor runner crashed in Node (Homebrew Node + shared libuv). Install Node 22 LTS (`brew install node@22`) and retry.";
161
+ var HOMEBREW_LIBUV_SUMMARY = "Cursor runner crashed in Node (Homebrew Node + shared libuv). Install Node 24 LTS (`brew install node@24`) and retry.";
154
162
  var BUNDLED_NODE_CRASH_SUMMARY = "Cursor runner crashed in Node. Retry the turn.";
155
163
  var V8_OOM_SUMMARY = "Agent ran out of memory (JavaScript heap). If it keeps happening, exclude large files from the project folder.";
156
164
  var MINIFIED_DUMP_SUMMARY = "Cursor local agent crashed during startup (truncated crash dump)";
@@ -265,7 +273,7 @@ function humanizeAgentFailDetail(detail) {
265
273
  return /ran out of memory/i.test(raw) ? raw : V8_OOM_SUMMARY;
266
274
  }
267
275
  if (/homebrew node \+ shared libuv|Cellar\/(?:libuv|node)|libuv\.\d+\.dylib/i.test(raw)) {
268
- return /brew install node@22/i.test(raw) ? raw : `${raw} \u2014 install Node 22 LTS (\`brew install node@22\`) and retry.`;
276
+ return /brew install node@(?:22|24)/i.test(raw) ? raw : `${raw} \u2014 install Node 24 LTS (\`brew install node@24\`) and retry.`;
269
277
  }
270
278
  if (/uv_run|spineventloopinternal|uv__io_poll|cursor runner crashed in node/i.test(lower)) {
271
279
  return /retry the turn/i.test(raw) ? raw : BUNDLED_NODE_CRASH_SUMMARY;
@@ -549,7 +557,7 @@ function unpackedAsarPath(filePath) {
549
557
  function nodeReadableScriptPath(scriptPath) {
550
558
  return unpackedAsarPath(scriptPath) ?? scriptPath;
551
559
  }
552
- var PREFERRED_LTS_MAJORS = [24, 22, 20];
560
+ var PREFERRED_LTS_MAJORS = [24, 22];
553
561
  function parseNodeMajor(version) {
554
562
  const match = /^v?(\d+)/.exec(version.trim());
555
563
  if (!match) return null;
@@ -559,7 +567,7 @@ function parseNodeMajor(version) {
559
567
  function scoreNodeForAgentRuntime(candidate) {
560
568
  const major = parseNodeMajor(candidate.version);
561
569
  if (major == null) return Number.NEGATIVE_INFINITY;
562
- if (major < 20) return major - 100;
570
+ if (major < 22) return major - 100;
563
571
  const posix = candidate.path.replace(/\\/g, "/");
564
572
  let score = 0;
565
573
  if (major % 2 === 0) {
@@ -229,13 +229,21 @@ function looksLikeHugeToolResultDump(text) {
229
229
  if (t.length < 4e3) return false;
230
230
  return looksLikeMinifiedJsDump(t);
231
231
  }
232
+ function looksLikeJobWaitResult(rec) {
233
+ if (typeof rec.delta === "string") {
234
+ return typeof rec.status === "string" || typeof rec.id === "string" || typeof rec.stillRunning === "boolean";
235
+ }
236
+ if (typeof rec.stopped === "boolean") {
237
+ return typeof rec.id === "string" || typeof rec.status === "string";
238
+ }
239
+ return rec.started === true || rec.reason === "already-running";
240
+ }
232
241
  function clipJobWaitResultJson(content) {
233
242
  const trimmed = content.trim();
234
243
  if (!trimmed.startsWith("{")) return void 0;
235
244
  try {
236
245
  const rec = JSON.parse(trimmed);
237
- const isJob = typeof rec.stillRunning === "boolean" || typeof rec.stopped === "boolean" || typeof rec.delta === "string" && typeof rec.status === "string";
238
- if (!isJob) return void 0;
246
+ if (!looksLikeJobWaitResult(rec)) return void 0;
239
247
  if (typeof rec.delta === "string" && rec.delta.length > 3500) {
240
248
  rec.delta = `\u2026(truncated ${rec.delta.length} chars)
241
249
  ${rec.delta.slice(-3500)}`;
@@ -293,7 +301,7 @@ function looksLikeHomebrewLibuvCrash(text) {
293
301
  return /Cellar\/(?:libuv|node)|libuv\.\d+\.dylib/i.test(text);
294
302
  }
295
303
  var NESTED_ELECTRON_SUMMARY = "Cursor local agent crashed at Electron startup (nested Chromium / HasCustomHostObject)";
296
- var HOMEBREW_LIBUV_SUMMARY = "Cursor runner crashed in Node (Homebrew Node + shared libuv). Install Node 22 LTS (`brew install node@22`) and retry.";
304
+ var HOMEBREW_LIBUV_SUMMARY = "Cursor runner crashed in Node (Homebrew Node + shared libuv). Install Node 24 LTS (`brew install node@24`) and retry.";
297
305
  var BUNDLED_NODE_CRASH_SUMMARY = "Cursor runner crashed in Node. Retry the turn.";
298
306
  var V8_OOM_SUMMARY = "Agent ran out of memory (JavaScript heap). If it keeps happening, exclude large files from the project folder.";
299
307
  var MINIFIED_DUMP_SUMMARY = "Cursor local agent crashed during startup (truncated crash dump)";
@@ -408,7 +416,7 @@ function humanizeAgentFailDetail(detail) {
408
416
  return /ran out of memory/i.test(raw) ? raw : V8_OOM_SUMMARY;
409
417
  }
410
418
  if (/homebrew node \+ shared libuv|Cellar\/(?:libuv|node)|libuv\.\d+\.dylib/i.test(raw)) {
411
- return /brew install node@22/i.test(raw) ? raw : `${raw} \u2014 install Node 22 LTS (\`brew install node@22\`) and retry.`;
419
+ return /brew install node@(?:22|24)/i.test(raw) ? raw : `${raw} \u2014 install Node 24 LTS (\`brew install node@24\`) and retry.`;
412
420
  }
413
421
  if (/uv_run|spineventloopinternal|uv__io_poll|cursor runner crashed in node/i.test(lower)) {
414
422
  return /retry the turn/i.test(raw) ? raw : BUNDLED_NODE_CRASH_SUMMARY;
@@ -1533,7 +1541,7 @@ function unpackedAsarPath(filePath) {
1533
1541
  function nodeReadableScriptPath(scriptPath) {
1534
1542
  return unpackedAsarPath(scriptPath) ?? scriptPath;
1535
1543
  }
1536
- var PREFERRED_LTS_MAJORS = [24, 22, 20];
1544
+ var PREFERRED_LTS_MAJORS = [24, 22];
1537
1545
  function parseNodeMajor(version) {
1538
1546
  const match = /^v?(\d+)/.exec(version.trim());
1539
1547
  if (!match) return null;
@@ -1543,7 +1551,7 @@ function parseNodeMajor(version) {
1543
1551
  function scoreNodeForAgentRuntime(candidate) {
1544
1552
  const major = parseNodeMajor(candidate.version);
1545
1553
  if (major == null) return Number.NEGATIVE_INFINITY;
1546
- if (major < 20) return major - 100;
1554
+ if (major < 22) return major - 100;
1547
1555
  const posix = candidate.path.replace(/\\/g, "/");
1548
1556
  let score = 0;
1549
1557
  if (major % 2 === 0) {
@@ -33,7 +33,7 @@ import {
33
33
  summarizeTurnStderr,
34
34
  toolDescription,
35
35
  turnFailChatText
36
- } from "./chunk-QU663NPO.js";
36
+ } from "./chunk-GBWKMWUQ.js";
37
37
  import {
38
38
  extractPresentedPlan,
39
39
  readPlanFile,
@@ -402,7 +402,7 @@ async function continueSourceThread(threadId, prompt) {
402
402
  await continueOnReply(threadId, prompt);
403
403
  return;
404
404
  }
405
- const { getOrchestrator: getOrchestrator2 } = await import("./orchestrator-EVDOHS2S.js");
405
+ const { getOrchestrator: getOrchestrator2 } = await import("./orchestrator-BHJELEFM.js");
406
406
  await getOrchestrator2().send(threadId, prompt);
407
407
  } catch {
408
408
  }
@@ -6458,7 +6458,7 @@ function formatScheduledPrompt(name, prompt) {
6458
6458
  ${prompt}`;
6459
6459
  }
6460
6460
  async function defaultDeps() {
6461
- const { getOrchestrator: getOrchestrator2, startOrchestration: startOrchestration2 } = await import("./orchestrator-EVDOHS2S.js");
6461
+ const { getOrchestrator: getOrchestrator2, startOrchestration: startOrchestration2 } = await import("./orchestrator-BHJELEFM.js");
6462
6462
  const orch = getOrchestrator2();
6463
6463
  return {
6464
6464
  findThread: (id) => findThreadByRef(id),
@@ -29,7 +29,7 @@ import {
29
29
  packagedMcpStdioPath,
30
30
  parseCursorRunnerLine,
31
31
  resolveNodeLaunch
32
- } from "./chunk-ZSFQLR7Y.js";
32
+ } from "./chunk-FY64F2ZQ.js";
33
33
  import {
34
34
  claudeChromeEnabled,
35
35
  isAbleTimeConnected,
@@ -24,7 +24,7 @@ import {
24
24
  stripBrightsyNdjsonNoise,
25
25
  sumUsageList,
26
26
  toolDescription
27
- } from "./chunk-ISOCLQEX.js";
27
+ } from "./chunk-OLDZXO53.js";
28
28
  import {
29
29
  SLACK_REPLY_FORMATTING,
30
30
  addWorkspace,
@@ -124,7 +124,7 @@ import {
124
124
  shouldRetryFailedAgentTurn,
125
125
  summarizeTurnStderr,
126
126
  turnFailChatText
127
- } from "./chunk-ZSFQLR7Y.js";
127
+ } from "./chunk-FY64F2ZQ.js";
128
128
  import {
129
129
  assertOrchestratorCapableAgent,
130
130
  childEnvWithAppSettings,
@@ -467,7 +467,7 @@ async function continueSourceThread(threadId, prompt) {
467
467
  await continueOnReply(threadId, prompt);
468
468
  return;
469
469
  }
470
- const { getOrchestrator: getOrchestrator2 } = await import("./orchestrator-CWBYGHAT.js");
470
+ const { getOrchestrator: getOrchestrator2 } = await import("./orchestrator-HWNGCDGW.js");
471
471
  await getOrchestrator2().send(threadId, prompt);
472
472
  } catch {
473
473
  }
@@ -3874,7 +3874,7 @@ async function createThread(input, _onSetupLine) {
3874
3874
  return readThread(thread.id) ?? thread;
3875
3875
  }
3876
3876
  async function listLinearIssues(agent, repoPath) {
3877
- const { getAdapter: getAdapter2 } = await import("./agents-XPWKGOVT.js");
3877
+ const { getAdapter: getAdapter2 } = await import("./agents-DTPVTDB5.js");
3878
3878
  await requireAgent(agent, { requireLinear: true });
3879
3879
  const adapter = getAdapter2(agent);
3880
3880
  if (!adapter.listLinearIssues) {
@@ -6805,7 +6805,7 @@ function formatScheduledPrompt(name, prompt) {
6805
6805
  ${prompt}`;
6806
6806
  }
6807
6807
  async function defaultDeps() {
6808
- const { getOrchestrator: getOrchestrator2, startOrchestration: startOrchestration2 } = await import("./orchestrator-CWBYGHAT.js");
6808
+ const { getOrchestrator: getOrchestrator2, startOrchestration: startOrchestration2 } = await import("./orchestrator-HWNGCDGW.js");
6809
6809
  const orch = getOrchestrator2();
6810
6810
  return {
6811
6811
  findThread: (id) => findThreadByRef(id),
package/dist/index.cjs CHANGED
@@ -8687,13 +8687,21 @@ function looksLikeHugeToolResultDump(text7) {
8687
8687
  if (t.length < 4e3) return false;
8688
8688
  return looksLikeMinifiedJsDump(t);
8689
8689
  }
8690
+ function looksLikeJobWaitResult(rec) {
8691
+ if (typeof rec.delta === "string") {
8692
+ return typeof rec.status === "string" || typeof rec.id === "string" || typeof rec.stillRunning === "boolean";
8693
+ }
8694
+ if (typeof rec.stopped === "boolean") {
8695
+ return typeof rec.id === "string" || typeof rec.status === "string";
8696
+ }
8697
+ return rec.started === true || rec.reason === "already-running";
8698
+ }
8690
8699
  function clipJobWaitResultJson(content) {
8691
8700
  const trimmed = content.trim();
8692
8701
  if (!trimmed.startsWith("{")) return void 0;
8693
8702
  try {
8694
8703
  const rec = JSON.parse(trimmed);
8695
- const isJob = typeof rec.stillRunning === "boolean" || typeof rec.stopped === "boolean" || typeof rec.delta === "string" && typeof rec.status === "string";
8696
- if (!isJob) return void 0;
8704
+ if (!looksLikeJobWaitResult(rec)) return void 0;
8697
8705
  if (typeof rec.delta === "string" && rec.delta.length > 3500) {
8698
8706
  rec.delta = `\u2026(truncated ${rec.delta.length} chars)
8699
8707
  ${rec.delta.slice(-3500)}`;
@@ -8859,7 +8867,7 @@ function humanizeAgentFailDetail(detail) {
8859
8867
  return /ran out of memory/i.test(raw) ? raw : V8_OOM_SUMMARY;
8860
8868
  }
8861
8869
  if (/homebrew node \+ shared libuv|Cellar\/(?:libuv|node)|libuv\.\d+\.dylib/i.test(raw)) {
8862
- return /brew install node@22/i.test(raw) ? raw : `${raw} \u2014 install Node 22 LTS (\`brew install node@22\`) and retry.`;
8870
+ return /brew install node@(?:22|24)/i.test(raw) ? raw : `${raw} \u2014 install Node 24 LTS (\`brew install node@24\`) and retry.`;
8863
8871
  }
8864
8872
  if (/uv_run|spineventloopinternal|uv__io_poll|cursor runner crashed in node/i.test(lower)) {
8865
8873
  return /retry the turn/i.test(raw) ? raw : BUNDLED_NODE_CRASH_SUMMARY;
@@ -8937,7 +8945,7 @@ var init_error_detail = __esm({
8937
8945
  "use strict";
8938
8946
  NODE_VERSION_FOOTER = /^Node\.js v\d+/i;
8939
8947
  NESTED_ELECTRON_SUMMARY = "Cursor local agent crashed at Electron startup (nested Chromium / HasCustomHostObject)";
8940
- HOMEBREW_LIBUV_SUMMARY = "Cursor runner crashed in Node (Homebrew Node + shared libuv). Install Node 22 LTS (`brew install node@22`) and retry.";
8948
+ HOMEBREW_LIBUV_SUMMARY = "Cursor runner crashed in Node (Homebrew Node + shared libuv). Install Node 24 LTS (`brew install node@24`) and retry.";
8941
8949
  BUNDLED_NODE_CRASH_SUMMARY = "Cursor runner crashed in Node. Retry the turn.";
8942
8950
  V8_OOM_SUMMARY = "Agent ran out of memory (JavaScript heap). If it keeps happening, exclude large files from the project folder.";
8943
8951
  MINIFIED_DUMP_SUMMARY = "Cursor local agent crashed during startup (truncated crash dump)";
@@ -10807,7 +10815,7 @@ function parseNodeMajor(version) {
10807
10815
  function scoreNodeForAgentRuntime(candidate) {
10808
10816
  const major = parseNodeMajor(candidate.version);
10809
10817
  if (major == null) return Number.NEGATIVE_INFINITY;
10810
- if (major < 20) return major - 100;
10818
+ if (major < 22) return major - 100;
10811
10819
  const posix = candidate.path.replace(/\\/g, "/");
10812
10820
  let score = 0;
10813
10821
  if (major % 2 === 0) {
@@ -10968,7 +10976,7 @@ var init_node_launch = __esm({
10968
10976
  init_packaged_runtime();
10969
10977
  AGENT_RUNNER_MAX_OLD_SPACE_MB = 8192;
10970
10978
  MAX_OLD_SPACE_FLAG = /(?:^|\s)(--max[-_]old[-_]space[-_]size)(?:[= ](\d+))?(?=\s|$)/;
10971
- PREFERRED_LTS_MAJORS = [24, 22, 20];
10979
+ PREFERRED_LTS_MAJORS = [24, 22];
10972
10980
  }
10973
10981
  });
10974
10982
 
@@ -24745,7 +24753,14 @@ function resolveLinearCycle(team, cycle) {
24745
24753
  }
24746
24754
  const lower = s.toLowerCase();
24747
24755
  const asNumber = Number.parseInt(s, 10);
24748
- const cycles = team.cycles ?? [];
24756
+ const seen = /* @__PURE__ */ new Set();
24757
+ const cycles = [team.activeCycle, ...team.cycles ?? []].filter(
24758
+ (c) => {
24759
+ if (!c?.id || seen.has(c.id)) return false;
24760
+ seen.add(c.id);
24761
+ return true;
24762
+ }
24763
+ );
24749
24764
  const found = cycles.find((c) => c.id === s) || cycles.find((c) => c.name.toLowerCase() === lower) || (Number.isInteger(asNumber) ? cycles.find((c) => c.number === asNumber) : void 0);
24750
24765
  if (!found) {
24751
24766
  const available = cycles.map((c) => c.number != null ? `${c.name} (${c.number})` : c.name).join(", ") || "(none)";
@@ -24862,7 +24877,12 @@ async function listLinearCommentsSince(opts) {
24862
24877
  first,
24863
24878
  filter: {
24864
24879
  createdAt: { gte: opts.since },
24865
- issue: buildLinearIssueFilter({ assignee, query: query || void 0 })
24880
+ issue: buildLinearIssueFilter({
24881
+ assignee,
24882
+ // Search hits may match identifier/comments — do not also require
24883
+ // title/description contains when an allowlist is already applied.
24884
+ query: restrictToIssues ? void 0 : query || void 0
24885
+ })
24866
24886
  }
24867
24887
  },
24868
24888
  opts
@@ -25163,7 +25183,7 @@ async function listGitHubIssueCommentsSince(opts) {
25163
25183
  }).filter((n) => n != null)
25164
25184
  );
25165
25185
  if (restrictToIssues && allowed.size === 0) return [];
25166
- const pageSize = Math.min(GITHUB_ISSUE_COMMENTS_PAGE_SIZE, Math.max(1, limit));
25186
+ const pageSize = GITHUB_ISSUE_COMMENTS_PAGE_SIZE;
25167
25187
  const out = [];
25168
25188
  for (let page = 1; page <= GITHUB_ISSUE_COMMENTS_MAX_PAGES; page++) {
25169
25189
  const path2 = `repos/${slug}/issues/comments?since=${encodeURIComponent(opts.since)}&sort=created&direction=desc&per_page=${pageSize}&page=${page}`;
package/dist/index.d.cts CHANGED
@@ -3161,8 +3161,8 @@ declare function allAdapters(): AgentAdapter[];
3161
3161
  * links Cellar `libuv`. That combo has aborted in `uv_run` while running
3162
3162
  * Cursor's local agent. The packaged app ships official Node 22 in
3163
3163
  * extraResources (`node/bin/node`) and prefers it. Unpackaged / CLI still
3164
- * probe `node -v` and prefer even LTS ≥20 — do not trust keg names
3165
- * (`opt/node@22` can alias Current).
3164
+ * probe `node -v` and prefer even LTS ≥22 — do not trust keg names
3165
+ * (`opt/node@22` can alias Current). Node 20 is EOL; do not probe that keg.
3166
3166
  */
3167
3167
  /**
3168
3168
  * Node CLIs (Claude Code, OpenCode, Brightsy, Cursor runner) and Node MCP
package/dist/index.d.ts CHANGED
@@ -3161,8 +3161,8 @@ declare function allAdapters(): AgentAdapter[];
3161
3161
  * links Cellar `libuv`. That combo has aborted in `uv_run` while running
3162
3162
  * Cursor's local agent. The packaged app ships official Node 22 in
3163
3163
  * extraResources (`node/bin/node`) and prefers it. Unpackaged / CLI still
3164
- * probe `node -v` and prefer even LTS ≥20 — do not trust keg names
3165
- * (`opt/node@22` can alias Current).
3164
+ * probe `node -v` and prefer even LTS ≥22 — do not trust keg names
3165
+ * (`opt/node@22` can alias Current). Node 20 is EOL; do not probe that keg.
3166
3166
  */
3167
3167
  /**
3168
3168
  * Node CLIs (Claude Code, OpenCode, Brightsy, Cursor runner) and Node MCP
package/dist/index.js CHANGED
@@ -238,7 +238,7 @@ import {
238
238
  worktreeCleanupSettings,
239
239
  wrapReviewSkillMarkdown,
240
240
  writeWorktreeFile
241
- } from "./chunk-U6FCBOS7.js";
241
+ } from "./chunk-Z6TW3A5P.js";
242
242
  import {
243
243
  LEGACY_PLAN_FILE_REL,
244
244
  PLAN_FILE_NAME,
@@ -344,7 +344,7 @@ import {
344
344
  withEventParentId,
345
345
  withEventsParentId,
346
346
  writeInjectedMcpConfig
347
- } from "./chunk-ISOCLQEX.js";
347
+ } from "./chunk-OLDZXO53.js";
348
348
  import {
349
349
  CLOUD_COORDINATOR_BUSY_REPLY,
350
350
  CLOUD_COORDINATOR_STOPPED_REPLY,
@@ -553,7 +553,7 @@ import {
553
553
  trustSystemCertificates,
554
554
  turnCostUsdFromCursorUsage,
555
555
  withMaxOldSpaceSize
556
- } from "./chunk-ZSFQLR7Y.js";
556
+ } from "./chunk-FY64F2ZQ.js";
557
557
  import {
558
558
  FOLLOW_UP_BEHAVIORS,
559
559
  GITHUB_GIT_AUTH_MODES,
@@ -1554,7 +1554,14 @@ function resolveLinearCycle(team, cycle) {
1554
1554
  }
1555
1555
  const lower = s.toLowerCase();
1556
1556
  const asNumber = Number.parseInt(s, 10);
1557
- const cycles = team.cycles ?? [];
1557
+ const seen = /* @__PURE__ */ new Set();
1558
+ const cycles = [team.activeCycle, ...team.cycles ?? []].filter(
1559
+ (c) => {
1560
+ if (!c?.id || seen.has(c.id)) return false;
1561
+ seen.add(c.id);
1562
+ return true;
1563
+ }
1564
+ );
1558
1565
  const found = cycles.find((c) => c.id === s) || cycles.find((c) => c.name.toLowerCase() === lower) || (Number.isInteger(asNumber) ? cycles.find((c) => c.number === asNumber) : void 0);
1559
1566
  if (!found) {
1560
1567
  const available = cycles.map((c) => c.number != null ? `${c.name} (${c.number})` : c.name).join(", ") || "(none)";
@@ -1671,7 +1678,12 @@ async function listLinearCommentsSince(opts) {
1671
1678
  first,
1672
1679
  filter: {
1673
1680
  createdAt: { gte: opts.since },
1674
- issue: buildLinearIssueFilter({ assignee, query: query || void 0 })
1681
+ issue: buildLinearIssueFilter({
1682
+ assignee,
1683
+ // Search hits may match identifier/comments — do not also require
1684
+ // title/description contains when an allowlist is already applied.
1685
+ query: restrictToIssues ? void 0 : query || void 0
1686
+ })
1675
1687
  }
1676
1688
  },
1677
1689
  opts
@@ -1970,7 +1982,7 @@ async function listGitHubIssueCommentsSince(opts) {
1970
1982
  }).filter((n) => n != null)
1971
1983
  );
1972
1984
  if (restrictToIssues && allowed.size === 0) return [];
1973
- const pageSize = Math.min(GITHUB_ISSUE_COMMENTS_PAGE_SIZE, Math.max(1, limit));
1985
+ const pageSize = GITHUB_ISSUE_COMMENTS_PAGE_SIZE;
1974
1986
  const out = [];
1975
1987
  for (let page = 1; page <= GITHUB_ISSUE_COMMENTS_MAX_PAGES; page++) {
1976
1988
  const path2 = `repos/${slug}/issues/comments?since=${encodeURIComponent(opts.since)}&sort=created&direction=desc&per_page=${pageSize}&page=${page}`;
@@ -1610,13 +1610,21 @@ function looksLikeHugeToolResultDump(text7) {
1610
1610
  if (t.length < 4e3) return false;
1611
1611
  return looksLikeMinifiedJsDump(t);
1612
1612
  }
1613
+ function looksLikeJobWaitResult(rec) {
1614
+ if (typeof rec.delta === "string") {
1615
+ return typeof rec.status === "string" || typeof rec.id === "string" || typeof rec.stillRunning === "boolean";
1616
+ }
1617
+ if (typeof rec.stopped === "boolean") {
1618
+ return typeof rec.id === "string" || typeof rec.status === "string";
1619
+ }
1620
+ return rec.started === true || rec.reason === "already-running";
1621
+ }
1613
1622
  function clipJobWaitResultJson(content) {
1614
1623
  const trimmed = content.trim();
1615
1624
  if (!trimmed.startsWith("{")) return void 0;
1616
1625
  try {
1617
1626
  const rec = JSON.parse(trimmed);
1618
- const isJob = typeof rec.stillRunning === "boolean" || typeof rec.stopped === "boolean" || typeof rec.delta === "string" && typeof rec.status === "string";
1619
- if (!isJob) return void 0;
1627
+ if (!looksLikeJobWaitResult(rec)) return void 0;
1620
1628
  if (typeof rec.delta === "string" && rec.delta.length > 3500) {
1621
1629
  rec.delta = `\u2026(truncated ${rec.delta.length} chars)
1622
1630
  ${rec.delta.slice(-3500)}`;
@@ -1782,7 +1790,7 @@ function humanizeAgentFailDetail(detail) {
1782
1790
  return /ran out of memory/i.test(raw) ? raw : V8_OOM_SUMMARY;
1783
1791
  }
1784
1792
  if (/homebrew node \+ shared libuv|Cellar\/(?:libuv|node)|libuv\.\d+\.dylib/i.test(raw)) {
1785
- return /brew install node@22/i.test(raw) ? raw : `${raw} \u2014 install Node 22 LTS (\`brew install node@22\`) and retry.`;
1793
+ return /brew install node@(?:22|24)/i.test(raw) ? raw : `${raw} \u2014 install Node 24 LTS (\`brew install node@24\`) and retry.`;
1786
1794
  }
1787
1795
  if (/uv_run|spineventloopinternal|uv__io_poll|cursor runner crashed in node/i.test(lower)) {
1788
1796
  return /retry the turn/i.test(raw) ? raw : BUNDLED_NODE_CRASH_SUMMARY;
@@ -1860,7 +1868,7 @@ var init_error_detail = __esm({
1860
1868
  "use strict";
1861
1869
  NODE_VERSION_FOOTER = /^Node\.js v\d+/i;
1862
1870
  NESTED_ELECTRON_SUMMARY = "Cursor local agent crashed at Electron startup (nested Chromium / HasCustomHostObject)";
1863
- HOMEBREW_LIBUV_SUMMARY = "Cursor runner crashed in Node (Homebrew Node + shared libuv). Install Node 22 LTS (`brew install node@22`) and retry.";
1871
+ HOMEBREW_LIBUV_SUMMARY = "Cursor runner crashed in Node (Homebrew Node + shared libuv). Install Node 24 LTS (`brew install node@24`) and retry.";
1864
1872
  BUNDLED_NODE_CRASH_SUMMARY = "Cursor runner crashed in Node. Retry the turn.";
1865
1873
  V8_OOM_SUMMARY = "Agent ran out of memory (JavaScript heap). If it keeps happening, exclude large files from the project folder.";
1866
1874
  MINIFIED_DUMP_SUMMARY = "Cursor local agent crashed during startup (truncated crash dump)";
@@ -9615,7 +9623,7 @@ function parseNodeMajor(version) {
9615
9623
  function scoreNodeForAgentRuntime(candidate) {
9616
9624
  const major = parseNodeMajor(candidate.version);
9617
9625
  if (major == null) return Number.NEGATIVE_INFINITY;
9618
- if (major < 20) return major - 100;
9626
+ if (major < 22) return major - 100;
9619
9627
  const posix = candidate.path.replace(/\\/g, "/");
9620
9628
  let score = 0;
9621
9629
  if (major % 2 === 0) {
@@ -9776,7 +9784,7 @@ var init_node_launch = __esm({
9776
9784
  init_packaged_runtime();
9777
9785
  AGENT_RUNNER_MAX_OLD_SPACE_MB = 8192;
9778
9786
  MAX_OLD_SPACE_FLAG = /(?:^|\s)(--max[-_]old[-_]space[-_]size)(?:[= ](\d+))?(?=\s|$)/;
9779
- PREFERRED_LTS_MAJORS = [24, 22, 20];
9787
+ PREFERRED_LTS_MAJORS = [24, 22];
9780
9788
  }
9781
9789
  });
9782
9790
 
@@ -21827,7 +21835,7 @@ async function listGitHubIssueCommentsSince(opts) {
21827
21835
  }).filter((n) => n != null)
21828
21836
  );
21829
21837
  if (restrictToIssues && allowed.size === 0) return [];
21830
- const pageSize = Math.min(GITHUB_ISSUE_COMMENTS_PAGE_SIZE, Math.max(1, limit));
21838
+ const pageSize = GITHUB_ISSUE_COMMENTS_PAGE_SIZE;
21831
21839
  const out = [];
21832
21840
  for (let page = 1; page <= GITHUB_ISSUE_COMMENTS_MAX_PAGES; page++) {
21833
21841
  const path = `repos/${slug}/issues/comments?since=${encodeURIComponent(opts.since)}&sort=created&direction=desc&per_page=${pageSize}&page=${page}`;
@@ -22492,7 +22500,14 @@ function resolveLinearCycle(team, cycle) {
22492
22500
  }
22493
22501
  const lower = s.toLowerCase();
22494
22502
  const asNumber = Number.parseInt(s, 10);
22495
- const cycles = team.cycles ?? [];
22503
+ const seen = /* @__PURE__ */ new Set();
22504
+ const cycles = [team.activeCycle, ...team.cycles ?? []].filter(
22505
+ (c) => {
22506
+ if (!c?.id || seen.has(c.id)) return false;
22507
+ seen.add(c.id);
22508
+ return true;
22509
+ }
22510
+ );
22496
22511
  const found = cycles.find((c) => c.id === s) || cycles.find((c) => c.name.toLowerCase() === lower) || (Number.isInteger(asNumber) ? cycles.find((c) => c.number === asNumber) : void 0);
22497
22512
  if (!found) {
22498
22513
  const available = cycles.map((c) => c.number != null ? `${c.name} (${c.number})` : c.name).join(", ") || "(none)";
@@ -22609,7 +22624,12 @@ async function listLinearCommentsSince(opts) {
22609
22624
  first,
22610
22625
  filter: {
22611
22626
  createdAt: { gte: opts.since },
22612
- issue: buildLinearIssueFilter({ assignee, query: query || void 0 })
22627
+ issue: buildLinearIssueFilter({
22628
+ assignee,
22629
+ // Search hits may match identifier/comments — do not also require
22630
+ // title/description contains when an allowlist is already applied.
22631
+ query: restrictToIssues ? void 0 : query || void 0
22632
+ })
22613
22633
  }
22614
22634
  },
22615
22635
  opts
@@ -37,7 +37,7 @@ import {
37
37
  syncBoardPins,
38
38
  updateSchedule,
39
39
  waitForDetachedJob
40
- } from "../chunk-LE5OZCKB.js";
40
+ } from "../chunk-IAOXW6RI.js";
41
41
  import {
42
42
  applySystemCaEnv,
43
43
  isCursorApiKeyConfigured,
@@ -46,7 +46,7 @@ import {
46
46
  materializeSystemCaBundle,
47
47
  sideboardMcpProfile,
48
48
  trustSystemCertificates
49
- } from "../chunk-QU663NPO.js";
49
+ } from "../chunk-GBWKMWUQ.js";
50
50
  import "../chunk-HVIEYTUK.js";
51
51
  import "../chunk-Y4MIXGPA.js";
52
52
  import {
@@ -298,7 +298,7 @@ async function listGitHubIssueCommentsSince(opts) {
298
298
  }).filter((n) => n != null)
299
299
  );
300
300
  if (restrictToIssues && allowed.size === 0) return [];
301
- const pageSize = Math.min(GITHUB_ISSUE_COMMENTS_PAGE_SIZE, Math.max(1, limit));
301
+ const pageSize = GITHUB_ISSUE_COMMENTS_PAGE_SIZE;
302
302
  const out = [];
303
303
  for (let page = 1; page <= GITHUB_ISSUE_COMMENTS_MAX_PAGES; page++) {
304
304
  const path = `repos/${slug}/issues/comments?since=${encodeURIComponent(opts.since)}&sort=created&direction=desc&per_page=${pageSize}&page=${page}`;
@@ -958,7 +958,14 @@ function resolveLinearCycle(team, cycle) {
958
958
  }
959
959
  const lower = s.toLowerCase();
960
960
  const asNumber = Number.parseInt(s, 10);
961
- const cycles = team.cycles ?? [];
961
+ const seen = /* @__PURE__ */ new Set();
962
+ const cycles = [team.activeCycle, ...team.cycles ?? []].filter(
963
+ (c) => {
964
+ if (!c?.id || seen.has(c.id)) return false;
965
+ seen.add(c.id);
966
+ return true;
967
+ }
968
+ );
962
969
  const found = cycles.find((c) => c.id === s) || cycles.find((c) => c.name.toLowerCase() === lower) || (Number.isInteger(asNumber) ? cycles.find((c) => c.number === asNumber) : void 0);
963
970
  if (!found) {
964
971
  const available = cycles.map((c) => c.number != null ? `${c.name} (${c.number})` : c.name).join(", ") || "(none)";
@@ -1075,7 +1082,12 @@ async function listLinearCommentsSince(opts) {
1075
1082
  first,
1076
1083
  filter: {
1077
1084
  createdAt: { gte: opts.since },
1078
- issue: buildLinearIssueFilter({ assignee, query: query || void 0 })
1085
+ issue: buildLinearIssueFilter({
1086
+ assignee,
1087
+ // Search hits may match identifier/comments — do not also require
1088
+ // title/description contains when an allowlist is already applied.
1089
+ query: restrictToIssues ? void 0 : query || void 0
1090
+ })
1079
1091
  }
1080
1092
  },
1081
1093
  opts
@@ -8,8 +8,8 @@ import {
8
8
  resolveSendFollowUp,
9
9
  startOrchestration,
10
10
  waitForPidExit
11
- } from "./chunk-LE5OZCKB.js";
12
- import "./chunk-QU663NPO.js";
11
+ } from "./chunk-IAOXW6RI.js";
12
+ import "./chunk-GBWKMWUQ.js";
13
13
  import "./chunk-HVIEYTUK.js";
14
14
  import "./chunk-Y4MIXGPA.js";
15
15
  import "./chunk-VKQGAWHY.js";
@@ -6,9 +6,9 @@ import {
6
6
  resolveSendFollowUp,
7
7
  startOrchestration,
8
8
  waitForPidExit
9
- } from "./chunk-U6FCBOS7.js";
9
+ } from "./chunk-Z6TW3A5P.js";
10
10
  import "./chunk-DJU54RYW.js";
11
- import "./chunk-ISOCLQEX.js";
11
+ import "./chunk-OLDZXO53.js";
12
12
  import "./chunk-VIODP5PT.js";
13
13
  import "./chunk-WXKXSZN4.js";
14
14
  import "./chunk-6K64FJDD.js";
@@ -16,7 +16,7 @@ import "./chunk-IEEAVWAP.js";
16
16
  import "./chunk-AN3THU7F.js";
17
17
  import "./chunk-N7WZ6NIN.js";
18
18
  import "./chunk-AXQ4ZWHK.js";
19
- import "./chunk-ZSFQLR7Y.js";
19
+ import "./chunk-FY64F2ZQ.js";
20
20
  import "./chunk-J7LQVLFQ.js";
21
21
  import "./chunk-4TR3HZFT.js";
22
22
  import "./chunk-AO35MGOE.js";
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@sideboard-ai/core",
3
- "version": "0.1.189",
3
+ "version": "0.1.190",
4
4
  "description": "Sideboard core — orchestration, agents, git worktrees, MCP server",
5
5
  "license": "Apache-2.0",
6
6
  "type": "module",