@sentry/junior 0.102.3 → 0.103.0

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.
Files changed (48) hide show
  1. package/dist/{agent-hooks-I4I2DHSW.js → agent-hooks-NHIXBJW3.js} +5 -5
  2. package/dist/api/conversations/schema.d.ts +16 -0
  3. package/dist/api/people/shared.d.ts +1 -1
  4. package/dist/api/schema.js +3 -3
  5. package/dist/api.js +13 -13
  6. package/dist/app.js +24 -72
  7. package/dist/chat/sandbox/runtime-dependencies.d.ts +2 -0
  8. package/dist/chat/sandbox/sandbox.d.ts +1 -0
  9. package/dist/chat/services/provider-retry.d.ts +1 -2
  10. package/dist/{chunk-ZSHL44IQ.js → chunk-4PDVOHXP.js} +1 -1
  11. package/dist/{chunk-F4CQEUTP.js → chunk-6FPTHPXF.js} +1 -1
  12. package/dist/{chunk-4YN2ZXKB.js → chunk-6LBNXC4F.js} +1 -1
  13. package/dist/{chunk-3OABPOHR.js → chunk-7G4J3CR7.js} +11 -2
  14. package/dist/{chunk-HYDQULR2.js → chunk-7LLRS2OK.js} +1 -0
  15. package/dist/{chunk-KFP3TZOS.js → chunk-B43K4C5K.js} +2 -2
  16. package/dist/{chunk-B5QS4AVO.js → chunk-BQCPAIAB.js} +2 -2
  17. package/dist/{chunk-EOB77KME.js → chunk-C4BT2P2K.js} +3 -3
  18. package/dist/{chunk-IQ36I3DF.js → chunk-CCTCIISK.js} +1 -1
  19. package/dist/{chunk-EMUZSROX.js → chunk-DEQZ23O3.js} +1 -1
  20. package/dist/{chunk-VSAFV2GI.js → chunk-E2VS47AZ.js} +3 -3
  21. package/dist/{chunk-NSP6OGL2.js → chunk-FW7DVHTL.js} +6 -4
  22. package/dist/{chunk-WPHCUGN7.js → chunk-GCGRQJR5.js} +1 -1
  23. package/dist/{chunk-DTUSCR2Y.js → chunk-GY5ZRYPH.js} +7 -7
  24. package/dist/{chunk-QZGVPPIJ.js → chunk-HOBDQQJY.js} +1 -1
  25. package/dist/{chunk-LJB2TLVT.js → chunk-HRDWLE7Q.js} +2 -2
  26. package/dist/{chunk-X2IPNCB5.js → chunk-JPXLAJUU.js} +58 -4
  27. package/dist/{chunk-5K4N73TP.js → chunk-JXQWOCBE.js} +3 -3
  28. package/dist/{chunk-SHBPSE7A.js → chunk-M3UAVLEN.js} +2 -3
  29. package/dist/{chunk-ZIX4PNBI.js → chunk-OE453VRG.js} +19 -15
  30. package/dist/{chunk-3UK5DFKW.js → chunk-U26ZWZCN.js} +1 -1
  31. package/dist/{chunk-4XNQSJAX.js → chunk-VKFOVMZL.js} +3 -3
  32. package/dist/cli/chat.js +14 -14
  33. package/dist/cli/plugins.js +5 -5
  34. package/dist/cli/snapshot-warmup.js +7 -3
  35. package/dist/cli/upgrade.js +7 -7
  36. package/dist/{db-6QP6HY7U.js → db-I343BSOM.js} +2 -2
  37. package/dist/{detail-OEIVZYXS.js → detail-ENVV4HIY.js} +10 -10
  38. package/dist/{detail-V37NTVBN.js → detail-UIOKVIET.js} +6 -6
  39. package/dist/{legacy-import-R3BMM2GH.js → legacy-import-M7VBOQTK.js} +3 -3
  40. package/dist/{list-FWLIZHSW.js → list-WR5U6JVM.js} +6 -6
  41. package/dist/{list-NTUT6A5M.js → list-XZ4HKQ4R.js} +6 -6
  42. package/dist/{list-AJ6RWBOG.js → list-ZOUSMSEH.js} +6 -6
  43. package/dist/{plugin-conversations-F3IBVNFX.js → plugin-conversations-DTUP4RH6.js} +5 -5
  44. package/dist/{profile-3FRQP4HP.js → profile-UO2N3XXG.js} +6 -6
  45. package/dist/{runner-C2ZTIOUD.js → runner-IEE5G4NV.js} +10 -10
  46. package/dist/{stats-7UFY6FPE.js → stats-NZIET4LT.js} +4 -4
  47. package/dist/{subagent-X3ZWJHR4.js → subagent-DY6XKTJ5.js} +9 -9
  48. package/package.json +5 -5
@@ -11,13 +11,13 @@ import {
11
11
  getPlugins,
12
12
  setPlugins,
13
13
  validatePlugins
14
- } from "./chunk-X2IPNCB5.js";
15
- import "./chunk-IQ36I3DF.js";
16
- import "./chunk-ZSHL44IQ.js";
17
- import "./chunk-QZGVPPIJ.js";
14
+ } from "./chunk-JPXLAJUU.js";
15
+ import "./chunk-CCTCIISK.js";
16
+ import "./chunk-4PDVOHXP.js";
17
+ import "./chunk-HOBDQQJY.js";
18
18
  import "./chunk-G3E7SCME.js";
19
19
  import "./chunk-4ZNGQH7C.js";
20
- import "./chunk-SHBPSE7A.js";
20
+ import "./chunk-M3UAVLEN.js";
21
21
  import "./chunk-FXFQNHRU.js";
22
22
  import "./chunk-RT5BUHR5.js";
23
23
  import "./chunk-B7PUBQQM.js";
@@ -126,6 +126,10 @@ export declare const transcriptRoleSchema: z.ZodEnum<{
126
126
  user: "user";
127
127
  }>;
128
128
  export declare const transcriptMessageSchema: z.ZodObject<{
129
+ outcome: z.ZodOptional<z.ZodEnum<{
130
+ error: "error";
131
+ aborted: "aborted";
132
+ }>>;
129
133
  parts: z.ZodArray<z.ZodObject<{
130
134
  bytes: z.ZodOptional<z.ZodNumber>;
131
135
  chars: z.ZodOptional<z.ZodNumber>;
@@ -442,6 +446,10 @@ export declare const conversationDetailReportSchema: z.ZodObject<{
442
446
  }, z.core.$strict>], "type">>>;
443
447
  transcriptAvailable: z.ZodBoolean;
444
448
  transcriptMetadata: z.ZodOptional<z.ZodArray<z.ZodObject<{
449
+ outcome: z.ZodOptional<z.ZodEnum<{
450
+ error: "error";
451
+ aborted: "aborted";
452
+ }>>;
445
453
  parts: z.ZodArray<z.ZodObject<{
446
454
  bytes: z.ZodOptional<z.ZodNumber>;
447
455
  chars: z.ZodOptional<z.ZodNumber>;
@@ -484,6 +492,10 @@ export declare const conversationDetailReportSchema: z.ZodObject<{
484
492
  transcriptExpired: z.ZodOptional<z.ZodBoolean>;
485
493
  transcriptExpiredAt: z.ZodOptional<z.ZodString>;
486
494
  transcript: z.ZodArray<z.ZodObject<{
495
+ outcome: z.ZodOptional<z.ZodEnum<{
496
+ error: "error";
497
+ aborted: "aborted";
498
+ }>>;
487
499
  parts: z.ZodArray<z.ZodObject<{
488
500
  bytes: z.ZodOptional<z.ZodNumber>;
489
501
  chars: z.ZodOptional<z.ZodNumber>;
@@ -547,6 +559,10 @@ export declare const conversationSubagentTranscriptReportSchema: z.ZodObject<{
547
559
  subagentKind: z.ZodString;
548
560
  subagentSentryConversationUrl: z.ZodOptional<z.ZodString>;
549
561
  transcript: z.ZodArray<z.ZodObject<{
562
+ outcome: z.ZodOptional<z.ZodEnum<{
563
+ error: "error";
564
+ aborted: "aborted";
565
+ }>>;
550
566
  parts: z.ZodArray<z.ZodObject<{
551
567
  bytes: z.ZodOptional<z.ZodNumber>;
552
568
  chars: z.ZodOptional<z.ZodNumber>;
@@ -1,6 +1,6 @@
1
1
  import type { ActorActivityDayReport, ConversationStatsItem, ActorTotalsReport } from "./schema";
2
2
  export declare const RECENT_LIMIT = 25;
3
- export declare const ACTIVITY_DAYS = 90;
3
+ export declare const ACTIVITY_DAYS = 365;
4
4
  /** Normalize emails before matching people API rows. */
5
5
  export declare function normalizeEmail(email: string | undefined): string | undefined;
6
6
  /** Build a zeroed totals object for people API aggregations. */
@@ -10,17 +10,17 @@ import {
10
10
  locationActivityDayReportSchema,
11
11
  locationDetailReportSchema,
12
12
  locationDirectoryReportSchema
13
- } from "../chunk-WPHCUGN7.js";
13
+ } from "../chunk-GCGRQJR5.js";
14
14
  import {
15
15
  actorDirectoryReportSchema,
16
16
  actorProfileReportSchema
17
- } from "../chunk-4YN2ZXKB.js";
17
+ } from "../chunk-6LBNXC4F.js";
18
18
  import {
19
19
  conversationDetailReportSchema,
20
20
  conversationFeedSchema,
21
21
  conversationStatsReportSchema,
22
22
  conversationSubagentTranscriptReportSchema
23
- } from "../chunk-HYDQULR2.js";
23
+ } from "../chunk-7LLRS2OK.js";
24
24
  import {
25
25
  healthReportSchema,
26
26
  pluginOperationalReportFeedSchema,
package/dist/api.js CHANGED
@@ -5,9 +5,9 @@ import {
5
5
  personParamsSchema,
6
6
  subagentParamsSchema
7
7
  } from "./chunk-2RNOB32R.js";
8
- import "./chunk-WPHCUGN7.js";
9
- import "./chunk-4YN2ZXKB.js";
10
- import "./chunk-HYDQULR2.js";
8
+ import "./chunk-GCGRQJR5.js";
9
+ import "./chunk-6LBNXC4F.js";
10
+ import "./chunk-7LLRS2OK.js";
11
11
  import {
12
12
  readHealthReport
13
13
  } from "./chunk-QNVHH5PU.js";
@@ -73,11 +73,11 @@ async function readRuntimeInfoReport() {
73
73
  }
74
74
  async function readPluginOperationalReportFeed() {
75
75
  const listRecent = async (listOptions) => {
76
- const { listRecentConversationSummaries } = await import("./plugin-conversations-F3IBVNFX.js");
76
+ const { listRecentConversationSummaries } = await import("./plugin-conversations-DTUP4RH6.js");
77
77
  return listRecentConversationSummaries(listOptions?.limit);
78
78
  };
79
79
  const nowMs = Date.now();
80
- const { getPluginOperationalReports } = await import("./agent-hooks-I4I2DHSW.js");
80
+ const { getPluginOperationalReports } = await import("./agent-hooks-NHIXBJW3.js");
81
81
  return pluginOperationalReportFeedSchema.parse({
82
82
  source: "plugins",
83
83
  generatedAt: new Date(nowMs).toISOString(),
@@ -126,7 +126,7 @@ function createJuniorApi() {
126
126
  return Response.json(await readPluginOperationalReportFeed());
127
127
  });
128
128
  app.get("/api/conversations", async (c) => {
129
- const { readConversationFeed } = await import("./list-AJ6RWBOG.js");
129
+ const { readConversationFeed } = await import("./list-ZOUSMSEH.js");
130
130
  const { actorEmail } = parseQuery(
131
131
  conversationFeedQuerySchema,
132
132
  c.req.query()
@@ -134,11 +134,11 @@ function createJuniorApi() {
134
134
  return Response.json(await readConversationFeed({ actorEmail }));
135
135
  });
136
136
  app.get("/api/conversations/stats", async () => {
137
- const { readConversationStats } = await import("./stats-7UFY6FPE.js");
137
+ const { readConversationStats } = await import("./stats-NZIET4LT.js");
138
138
  return Response.json(await readConversationStats());
139
139
  });
140
140
  app.get("/api/conversations/:conversationId", async (c) => {
141
- const { readConversationDetail } = await import("./detail-OEIVZYXS.js");
141
+ const { readConversationDetail } = await import("./detail-ENVV4HIY.js");
142
142
  const { conversationId } = parseParams(
143
143
  conversationParamsSchema,
144
144
  c.req.param()
@@ -149,7 +149,7 @@ function createJuniorApi() {
149
149
  app.get(
150
150
  "/api/conversations/:conversationId/subagents/:subagentId",
151
151
  async (c) => {
152
- const { readConversationSubagent } = await import("./subagent-X3ZWJHR4.js");
152
+ const { readConversationSubagent } = await import("./subagent-DY6XKTJ5.js");
153
153
  const { conversationId, subagentId } = parseParams(
154
154
  subagentParamsSchema,
155
155
  c.req.param()
@@ -159,21 +159,21 @@ function createJuniorApi() {
159
159
  }
160
160
  );
161
161
  app.get("/api/people", async () => {
162
- const { readPeopleList } = await import("./list-NTUT6A5M.js");
162
+ const { readPeopleList } = await import("./list-XZ4HKQ4R.js");
163
163
  return Response.json(await readPeopleList());
164
164
  });
165
165
  app.get("/api/people/:email", async (c) => {
166
166
  const { email } = parseParams(personParamsSchema, c.req.param());
167
- const { readPeopleProfile } = await import("./profile-3FRQP4HP.js");
167
+ const { readPeopleProfile } = await import("./profile-UO2N3XXG.js");
168
168
  return Response.json(await readPeopleProfile(email));
169
169
  });
170
170
  app.get("/api/locations", async () => {
171
- const { readLocationDirectory } = await import("./list-FWLIZHSW.js");
171
+ const { readLocationDirectory } = await import("./list-WR5U6JVM.js");
172
172
  return Response.json(await readLocationDirectory());
173
173
  });
174
174
  app.get("/api/locations/:locationId", async (c) => {
175
175
  const { locationId } = parseParams(locationParamsSchema, c.req.param());
176
- const { readLocationDetail } = await import("./detail-V37NTVBN.js");
176
+ const { readLocationDetail } = await import("./detail-UIOKVIET.js");
177
177
  const report = await readLocationDetail(locationId);
178
178
  return report ? Response.json(report) : Response.json({ error: "Location not found." }, { status: 404 });
179
179
  });
package/dist/app.js CHANGED
@@ -5,7 +5,7 @@ import {
5
5
  processPluginTask,
6
6
  requireTurnFailureEventId,
7
7
  scheduleSessionCompletedPluginTasks
8
- } from "./chunk-DTUSCR2Y.js";
8
+ } from "./chunk-GY5ZRYPH.js";
9
9
  import {
10
10
  buildSentryConversationUrl
11
11
  } from "./chunk-LVUKF5CE.js";
@@ -13,7 +13,7 @@ import {
13
13
  conversationVisibilityFromSlackChannelType,
14
14
  resolveSlackChannelTypeFromMessage,
15
15
  resolveSlackConversationContext
16
- } from "./chunk-EMUZSROX.js";
16
+ } from "./chunk-DEQZ23O3.js";
17
17
  import {
18
18
  CONVERSATION_WORK_CHECK_IN_INTERVAL_MS,
19
19
  CONVERSATION_WORK_STALE_ENQUEUE_MS,
@@ -37,7 +37,7 @@ import {
37
37
  requestConversationContinuation,
38
38
  requestConversationWork,
39
39
  startConversationWork
40
- } from "./chunk-3UK5DFKW.js";
40
+ } from "./chunk-U26ZWZCN.js";
41
41
  import {
42
42
  GET
43
43
  } from "./chunk-QNVHH5PU.js";
@@ -106,7 +106,7 @@ import {
106
106
  splitSlackReplyText,
107
107
  startOAuthFlow,
108
108
  truncateStatusText
109
- } from "./chunk-ZIX4PNBI.js";
109
+ } from "./chunk-OE453VRG.js";
110
110
  import {
111
111
  CooperativeTurnYieldError,
112
112
  TurnInputCommitLostError,
@@ -134,7 +134,7 @@ import {
134
134
  persistWithRetry,
135
135
  persistYieldSessionRecord,
136
136
  startActiveTurn
137
- } from "./chunk-5K4N73TP.js";
137
+ } from "./chunk-JXQWOCBE.js";
138
138
  import {
139
139
  JUNIOR_THREAD_STATE_TTL_MS,
140
140
  coerceThreadConversationState
@@ -145,13 +145,13 @@ import {
145
145
  getAgentTurnSessionRecord,
146
146
  listAgentTurnSessionSummariesForConversation,
147
147
  recordAgentTurnSessionSummary
148
- } from "./chunk-EOB77KME.js";
148
+ } from "./chunk-C4BT2P2K.js";
149
149
  import {
150
150
  commitMessages,
151
151
  loadConversationProjection,
152
152
  loadProjection,
153
153
  recordAuthorizationCompleted
154
- } from "./chunk-B5QS4AVO.js";
154
+ } from "./chunk-BQCPAIAB.js";
155
155
  import {
156
156
  buildConversationContext,
157
157
  createConversationMemoryService,
@@ -166,22 +166,24 @@ import {
166
166
  persistConversationMessages,
167
167
  updateConversationStats,
168
168
  upsertConversationMessage
169
- } from "./chunk-VSAFV2GI.js";
170
- import "./chunk-3OABPOHR.js";
169
+ } from "./chunk-E2VS47AZ.js";
170
+ import "./chunk-7G4J3CR7.js";
171
171
  import "./chunk-PDO5BLNM.js";
172
172
  import "./chunk-UIE3R5XU.js";
173
173
  import {
174
174
  bindScheduledTaskCredentialSubject,
175
175
  bindSlackDirectCredentialSubject,
176
+ getDashboardConversationLink,
176
177
  getPluginApiRoutes,
177
178
  getPluginRoutes,
178
179
  getPluginSlackConversationLink,
179
180
  getPlugins,
181
+ setDashboardConversationLinkOptions,
180
182
  setPlugins,
181
183
  validatePlugins,
182
184
  verifyScheduledTaskCredentialSubject,
183
185
  verifySlackDirectCredentialSubject
184
- } from "./chunk-X2IPNCB5.js";
186
+ } from "./chunk-JPXLAJUU.js";
185
187
  import {
186
188
  SlackActionError,
187
189
  downloadPrivateSlackFile,
@@ -192,11 +194,11 @@ import {
192
194
  normalizeSlackConversationId,
193
195
  runWithSlackInstallationToken,
194
196
  runWithWorkspaceTeamId
195
- } from "./chunk-IQ36I3DF.js";
197
+ } from "./chunk-CCTCIISK.js";
196
198
  import {
197
199
  createPluginLogger,
198
200
  createPluginState
199
- } from "./chunk-ZSHL44IQ.js";
201
+ } from "./chunk-4PDVOHXP.js";
200
202
  import {
201
203
  contextProvenance,
202
204
  getConversationStore,
@@ -206,7 +208,7 @@ import {
206
208
  juniorAgentSteps,
207
209
  juniorConversationMessages,
208
210
  juniorConversations
209
- } from "./chunk-QZGVPPIJ.js";
211
+ } from "./chunk-HOBDQQJY.js";
210
212
  import "./chunk-G3E7SCME.js";
211
213
  import {
212
214
  sleep
@@ -234,7 +236,7 @@ import {
234
236
  setSlackReactionConfig,
235
237
  stripRuntimeTurnContext,
236
238
  trimTrailingAssistantMessages
237
- } from "./chunk-SHBPSE7A.js";
239
+ } from "./chunk-M3UAVLEN.js";
238
240
  import {
239
241
  juniorDestinations
240
242
  } from "./chunk-FXFQNHRU.js";
@@ -305,56 +307,6 @@ import { createRequire } from "module";
305
307
  import { pathToFileURL } from "url";
306
308
  import { Hono } from "hono";
307
309
 
308
- // src/chat/slack/dashboard-link.ts
309
- var dashboardConversationLinkOptions;
310
- function withHttps(host) {
311
- return /^https?:\/\//.test(host) ? host : `https://${host}`;
312
- }
313
- function stripTrailingSlashes(value) {
314
- let end = value.length;
315
- while (end > 1 && value.charCodeAt(end - 1) === 47) {
316
- end -= 1;
317
- }
318
- return end === value.length ? value : value.slice(0, end);
319
- }
320
- function normalizeDashboardPath(path2, fallback) {
321
- const value = path2?.trim() || fallback;
322
- const withSlash = value.startsWith("/") ? value : `/${value}`;
323
- return stripTrailingSlashes(withSlash);
324
- }
325
- function resolveDashboardBaseURL(config) {
326
- const explicit = config.baseURL ?? process.env.JUNIOR_BASE_URL;
327
- if (explicit?.trim()) {
328
- return stripTrailingSlashes(withHttps(explicit.trim()));
329
- }
330
- const vercelProd = process.env.VERCEL_PROJECT_PRODUCTION_URL?.trim();
331
- if (vercelProd) {
332
- return stripTrailingSlashes(withHttps(vercelProd));
333
- }
334
- const vercelUrl = process.env.VERCEL_URL?.trim();
335
- if (vercelUrl) {
336
- return stripTrailingSlashes(withHttps(vercelUrl));
337
- }
338
- return "http://localhost:3000";
339
- }
340
- function setDashboardConversationLinkOptions(options) {
341
- const previous = dashboardConversationLinkOptions;
342
- dashboardConversationLinkOptions = options?.disabled ? void 0 : options;
343
- return previous;
344
- }
345
- function getDashboardConversationLink(conversationId) {
346
- if (!dashboardConversationLinkOptions) {
347
- return void 0;
348
- }
349
- const baseURL = resolveDashboardBaseURL(dashboardConversationLinkOptions);
350
- const basePath = normalizeDashboardPath(
351
- dashboardConversationLinkOptions.basePath,
352
- "/"
353
- );
354
- const path2 = basePath === "/" ? `/conversations/${encodeURIComponent(conversationId)}` : `${basePath}/conversations/${encodeURIComponent(conversationId)}`;
355
- return `${baseURL}${path2}`;
356
- }
357
-
358
310
  // src/chat/slack/footer.ts
359
311
  function buildSlackReplyFooter(args) {
360
312
  const items = [];
@@ -11715,21 +11667,21 @@ function isMissingDashboardPackage(error) {
11715
11667
  const code = error.code;
11716
11668
  return (code === "ERR_MODULE_NOT_FOUND" || code === "MODULE_NOT_FOUND") && error.message.includes("@sentry/junior-dashboard");
11717
11669
  }
11718
- function stripTrailingSlashes2(value) {
11670
+ function stripTrailingSlashes(value) {
11719
11671
  let end = value.length;
11720
11672
  while (end > 1 && value.charCodeAt(end - 1) === 47) {
11721
11673
  end -= 1;
11722
11674
  }
11723
11675
  return end === value.length ? value : value.slice(0, end);
11724
11676
  }
11725
- function normalizeDashboardPath2(path2, fallback) {
11677
+ function normalizeDashboardPath(path2, fallback) {
11726
11678
  const value = path2?.trim() || fallback;
11727
11679
  const withSlash = value.startsWith("/") ? value : `/${value}`;
11728
- return stripTrailingSlashes2(withSlash);
11680
+ return stripTrailingSlashes(withSlash);
11729
11681
  }
11730
11682
  function dashboardHostRoutePaths(dashboard) {
11731
- const basePath = normalizeDashboardPath2(dashboard.basePath, "/");
11732
- const authPath = normalizeDashboardPath2(dashboard.authPath, "/api/auth");
11683
+ const basePath = normalizeDashboardPath(dashboard.basePath, "/");
11684
+ const authPath = normalizeDashboardPath(dashboard.authPath, "/api/auth");
11733
11685
  const pagePath = (suffix) => basePath === "/" ? `/${suffix}` : `${basePath}/${suffix}`;
11734
11686
  const conversationsPath = pagePath("conversations");
11735
11687
  const peoplePath = pagePath("people");
@@ -11772,7 +11724,7 @@ function routePrefixCoversPath(routePrefix, path2) {
11772
11724
  return routePrefix === "/" || path2 === routePrefix || path2.startsWith(`${routePrefix}/`);
11773
11725
  }
11774
11726
  function routeSegments(path2) {
11775
- return normalizeDashboardPath2(path2, "/").split("/").filter(Boolean);
11727
+ return normalizeDashboardPath(path2, "/").split("/").filter(Boolean);
11776
11728
  }
11777
11729
  function routeSegmentMatches(pattern, value) {
11778
11730
  return pattern === value || pattern === "*" || pattern.startsWith(":");
@@ -11793,11 +11745,11 @@ function routePatternMatchesConcretePath(pattern, concretePath) {
11793
11745
  return patternSegments.length === pathSegments.length;
11794
11746
  }
11795
11747
  function routePatternExamples(routePath) {
11796
- const normalized = normalizeDashboardPath2(routePath, "/");
11748
+ const normalized = normalizeDashboardPath(routePath, "/");
11797
11749
  if (!normalized.endsWith("/*") && !normalized.endsWith("/**")) {
11798
11750
  return [normalized];
11799
11751
  }
11800
- const prefix = normalizeDashboardPath2(
11752
+ const prefix = normalizeDashboardPath(
11801
11753
  normalized.endsWith("/*") ? normalized.slice(0, -2) : normalized.slice(0, -3),
11802
11754
  "/"
11803
11755
  );
@@ -0,0 +1,2 @@
1
+ import type { PluginRuntimeDependency } from "@/chat/plugins/types";
2
+ export declare const GLOBAL_RUNTIME_DEPENDENCIES: PluginRuntimeDependency[];
@@ -20,6 +20,7 @@ export interface BashCustomCommandResult {
20
20
  exit_code: number;
21
21
  signal: null;
22
22
  timed_out: boolean;
23
+ aborted?: boolean;
23
24
  stdout: string;
24
25
  stderr: string;
25
26
  stdout_truncated: boolean;
@@ -1,4 +1,3 @@
1
- import type { AssistantMessage } from "@earendil-works/pi-ai";
2
1
  import type { PiMessage } from "@/chat/pi/messages";
3
2
  /** Mark failures that cross the AI provider boundary for shared retry handling. */
4
3
  export declare function createProviderError(error: unknown): Error;
@@ -7,8 +6,8 @@ export declare function isProviderRetryError(error: unknown): boolean;
7
6
  /** Build the next provider retry step from Pi history, if the turn can resume. */
8
7
  export declare function nextProviderRetry(args: {
9
8
  attempt: number;
10
- lastAssistant: Pick<AssistantMessage, "stopReason" | "errorMessage"> | undefined;
11
9
  messages: PiMessage[];
10
+ retryableFailure: boolean;
12
11
  }): {
13
12
  delayMs: number;
14
13
  messages: PiMessage[];
@@ -1,6 +1,6 @@
1
1
  import {
2
2
  getStateAdapter
3
- } from "./chunk-SHBPSE7A.js";
3
+ } from "./chunk-M3UAVLEN.js";
4
4
  import {
5
5
  logException,
6
6
  logInfo,
@@ -1,6 +1,6 @@
1
1
  import {
2
2
  juniorConversations
3
- } from "./chunk-QZGVPPIJ.js";
3
+ } from "./chunk-HOBDQQJY.js";
4
4
 
5
5
  // src/api/conversations/aggregate.ts
6
6
  import { sql } from "drizzle-orm";
@@ -2,7 +2,7 @@ import {
2
2
  actorIdentitySchema,
3
3
  conversationStatsItemSchema,
4
4
  conversationSummaryReportSchema
5
- } from "./chunk-HYDQULR2.js";
5
+ } from "./chunk-7LLRS2OK.js";
6
6
 
7
7
  // src/api/people/schema.ts
8
8
  import { z } from "zod";
@@ -7,7 +7,7 @@ import {
7
7
  import {
8
8
  getStateAdapter,
9
9
  toOptionalTrimmed
10
- } from "./chunk-SHBPSE7A.js";
10
+ } from "./chunk-M3UAVLEN.js";
11
11
  import {
12
12
  pluginCatalogRuntime
13
13
  } from "./chunk-77LHNQK4.js";
@@ -15,6 +15,11 @@ import {
15
15
  withSpan
16
16
  } from "./chunk-AEWZ7F65.js";
17
17
 
18
+ // src/chat/sandbox/runtime-dependencies.ts
19
+ var GLOBAL_RUNTIME_DEPENDENCIES = [
20
+ { type: "system", package: "docker" }
21
+ ];
22
+
18
23
  // src/chat/sandbox/runtime-dependency-snapshots.ts
19
24
  import { createHash } from "crypto";
20
25
  import { Sandbox } from "@vercel/sandbox";
@@ -180,7 +185,10 @@ function parseFloatingDepMaxAgeMs() {
180
185
  return parsed;
181
186
  }
182
187
  function buildDependencyProfile(runtime) {
183
- const dependencies = pluginCatalogRuntime.getRuntimeDependencies();
188
+ const dependencies = [
189
+ ...GLOBAL_RUNTIME_DEPENDENCIES,
190
+ ...pluginCatalogRuntime.getRuntimeDependencies()
191
+ ];
184
192
  const postinstall = pluginCatalogRuntime.getRuntimePostinstall();
185
193
  if (dependencies.length === 0 && postinstall.length === 0) {
186
194
  return null;
@@ -693,6 +701,7 @@ export {
693
701
  runNonInteractiveCommand,
694
702
  getVercelSandboxCredentials,
695
703
  getSandboxResources,
704
+ GLOBAL_RUNTIME_DEPENDENCIES,
696
705
  createSandboxInstance,
697
706
  getRuntimeDependencyProfileHash,
698
707
  resolveRuntimeDependencySnapshot,
@@ -76,6 +76,7 @@ var transcriptRoleSchema = z.enum([
76
76
  "user"
77
77
  ]);
78
78
  var transcriptMessageSchema = z.object({
79
+ outcome: z.enum(["error", "aborted"]).optional(),
79
80
  parts: z.array(transcriptPartSchema),
80
81
  role: transcriptRoleSchema,
81
82
  timestamp: z.number().optional()
@@ -3,7 +3,7 @@ import {
3
3
  juniorConversations,
4
4
  juniorIdentities,
5
5
  juniorUsers
6
- } from "./chunk-QZGVPPIJ.js";
6
+ } from "./chunk-HOBDQQJY.js";
7
7
  import {
8
8
  juniorDestinations
9
9
  } from "./chunk-FXFQNHRU.js";
@@ -11,7 +11,7 @@ import {
11
11
  // src/api/people/shared.ts
12
12
  import { and, asc, desc, eq, sql } from "drizzle-orm";
13
13
  var RECENT_LIMIT = 25;
14
- var ACTIVITY_DAYS = 90;
14
+ var ACTIVITY_DAYS = 365;
15
15
  function normalizeEmail(email) {
16
16
  const normalized = email?.trim().toLowerCase();
17
17
  return normalized || void 0;
@@ -1,10 +1,10 @@
1
1
  import {
2
2
  ensureLegacyConversationImport
3
- } from "./chunk-VSAFV2GI.js";
3
+ } from "./chunk-E2VS47AZ.js";
4
4
  import {
5
5
  contextProvenance,
6
6
  getAgentStepStore
7
- } from "./chunk-QZGVPPIJ.js";
7
+ } from "./chunk-HOBDQQJY.js";
8
8
 
9
9
  // src/chat/conversations/projection.ts
10
10
  import { isDeepStrictEqual } from "util";
@@ -1,7 +1,7 @@
1
1
  import {
2
2
  commitMessages,
3
3
  loadTurnProjection
4
- } from "./chunk-B5QS4AVO.js";
4
+ } from "./chunk-BQCPAIAB.js";
5
5
  import {
6
6
  usageSchema
7
7
  } from "./chunk-PDO5BLNM.js";
@@ -9,10 +9,10 @@ import {
9
9
  getConversationStore,
10
10
  instructionActors,
11
11
  instructionProvenanceFor
12
- } from "./chunk-QZGVPPIJ.js";
12
+ } from "./chunk-HOBDQQJY.js";
13
13
  import {
14
14
  getStateAdapter
15
- } from "./chunk-SHBPSE7A.js";
15
+ } from "./chunk-M3UAVLEN.js";
16
16
  import {
17
17
  toStoredSlackActor
18
18
  } from "./chunk-AEWZ7F65.js";
@@ -3,7 +3,7 @@ import {
3
3
  } from "./chunk-4ZNGQH7C.js";
4
4
  import {
5
5
  getSlackBotToken
6
- } from "./chunk-SHBPSE7A.js";
6
+ } from "./chunk-M3UAVLEN.js";
7
7
  import {
8
8
  logWarn,
9
9
  setSpanAttributes,
@@ -1,6 +1,6 @@
1
1
  import {
2
2
  normalizeSlackConversationId
3
- } from "./chunk-IQ36I3DF.js";
3
+ } from "./chunk-CCTCIISK.js";
4
4
  import {
5
5
  parseSlackThreadId
6
6
  } from "./chunk-RT5BUHR5.js";
@@ -12,14 +12,14 @@ import {
12
12
  piMessageSchema,
13
13
  readSessionLogEntries,
14
14
  sanitizePostgresJson
15
- } from "./chunk-QZGVPPIJ.js";
15
+ } from "./chunk-HOBDQQJY.js";
16
16
  import {
17
17
  botConfig,
18
18
  escapeXml,
19
19
  getStateAdapter,
20
20
  resolveGatewayModel,
21
21
  unescapeXml
22
- } from "./chunk-SHBPSE7A.js";
22
+ } from "./chunk-M3UAVLEN.js";
23
23
  import {
24
24
  logWarn,
25
25
  setSpanAttributes
@@ -465,7 +465,7 @@ async function hydrateConversationMessages(args) {
465
465
  args.conversation.messages = [];
466
466
  return;
467
467
  }
468
- const { ensureLegacyConversationImport: ensureLegacyConversationImport2 } = await import("./legacy-import-R3BMM2GH.js");
468
+ const { ensureLegacyConversationImport: ensureLegacyConversationImport2 } = await import("./legacy-import-M7VBOQTK.js");
469
469
  await ensureLegacyConversationImport2({ conversationId: args.conversationId });
470
470
  await hydrateConversationCompactions({
471
471
  conversation: args.conversation,
@@ -1,6 +1,6 @@
1
1
  import {
2
2
  conversationSummaryFromStoredConversation
3
- } from "./chunk-LJB2TLVT.js";
3
+ } from "./chunk-HRDWLE7Q.js";
4
4
  import {
5
5
  buildSentryConversationUrl,
6
6
  buildSentryTraceUrl
@@ -8,16 +8,16 @@ import {
8
8
  import {
9
9
  loadProjection,
10
10
  projectSteps
11
- } from "./chunk-B5QS4AVO.js";
11
+ } from "./chunk-BQCPAIAB.js";
12
12
  import {
13
13
  getAgentStepStore,
14
14
  getConversationMessageStore
15
- } from "./chunk-QZGVPPIJ.js";
15
+ } from "./chunk-HOBDQQJY.js";
16
16
  import {
17
17
  stripRuntimeTurnContext,
18
18
  unescapeXml,
19
19
  unwrapCurrentInstruction
20
- } from "./chunk-SHBPSE7A.js";
20
+ } from "./chunk-M3UAVLEN.js";
21
21
  import {
22
22
  canExposeConversationPayload
23
23
  } from "./chunk-RT5BUHR5.js";
@@ -161,6 +161,7 @@ function normalizeMessage(message, options = {}) {
161
161
  const role = transcriptRole(record.role);
162
162
  return {
163
163
  role,
164
+ ...role === "assistant" && (record.stopReason === "error" || record.stopReason === "aborted") ? { outcome: record.stopReason } : {},
164
165
  ...typeof record.timestamp === "number" ? { timestamp: record.timestamp } : {},
165
166
  parts: role === "toolResult" ? [normalizeToolResultMessage(record)] : Array.isArray(content) ? content.map(
166
167
  (part) => normalizeTranscriptPart(part, {
@@ -252,6 +253,7 @@ function redactTranscriptPart(part) {
252
253
  function redactTranscriptMessage(message) {
253
254
  return {
254
255
  role: message.role,
256
+ ...message.outcome ? { outcome: message.outcome } : {},
255
257
  ...typeof message.timestamp === "number" ? { timestamp: message.timestamp } : {},
256
258
  parts: message.parts.map(redactTranscriptPart)
257
259
  };
@@ -2,7 +2,7 @@ import {
2
2
  actorIdentitySchema,
3
3
  conversationStatsItemSchema,
4
4
  conversationSummaryReportSchema
5
- } from "./chunk-HYDQULR2.js";
5
+ } from "./chunk-7LLRS2OK.js";
6
6
  import {
7
7
  juniorDestinationKindSchema
8
8
  } from "./chunk-FXFQNHRU.js";