@sentry/junior 0.283.0 → 0.285.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.
- package/dist/{adapter-D8-lqOBF.js → adapter-DN5AB4VU.js} +37 -3
- package/dist/{admin-Dnw5SCXp.js → admin-DOITMKnn.js} +1 -1
- package/dist/{agent-runner-Bj7GhysW.js → agent-runner-BsWhHe4N.js} +583 -1655
- package/dist/api/schema.d.ts +2 -2
- package/dist/api/schema.js +8 -6
- package/dist/api.d.ts +1 -1
- package/dist/api.js +214 -43
- package/dist/{app-CMBP-N43.d.ts → app-DyMs9330.d.ts} +2 -2
- package/dist/app.d.ts +1 -1
- package/dist/app.js +230 -187
- package/dist/{assistant-reply-CdYsLbXL.js → assistant-reply-9Jip5bsr.js} +1 -1
- package/dist/{automation-MLWOrghe.js → automation-Mk8aaHzy.js} +2 -2
- package/dist/{background-compaction-queue-Bbsqx8Vm.js → background-compaction-queue-DXkLsWoH.js} +2 -2
- package/dist/{briefs-C4qBY-jb.js → briefs-Cl8-nK9B.js} +5 -5
- package/dist/{catalog-runtime-B7NRB7eH.js → catalog-runtime-Bte6jRB2.js} +1 -1
- package/dist/cli/chat.js +19 -16
- package/dist/cli/check.js +3 -3
- package/dist/cli/init.js +3 -0
- package/dist/cli/main.js +3 -3
- package/dist/cli/plugins.js +4 -4
- package/dist/cli/snapshot-create.js +4 -4
- package/dist/cli/upgrade.d.ts +1 -1
- package/dist/cli/upgrade.js +25 -4
- package/dist/{client-a3Ib6wxr.js → client-DDbBucBw.js} +2 -2
- package/dist/{config-DFVlYCeY.js → config-DqFnykQT.js} +1 -1
- package/dist/{connections-BtnvpBEV.js → connections-DA4LT9LL.js} +10 -10
- package/dist/{conversation-DdT7SNar.js → conversation-D8kVoCrP.js} +58 -6
- package/dist/{conversation-pending-messages-Dct5pheX.js → conversation-pending-messages-BvROq1bq.js} +1 -1
- package/dist/{conversation-privacy-DLq-abjU.js → conversation-privacy-D0j_h70R.js} +1 -1
- package/dist/{credential-sync-B4XFVcjM.js → credential-sync-hcsYatw-.js} +13 -13
- package/dist/{db-A_WrTY-s.d.ts → db-BhHZSuFw.d.ts} +18 -2
- package/dist/{executor-HPgHGAWK.js → executor-BLEMIgIZ.js} +29 -4
- package/dist/instrumentation.js +37 -13
- package/dist/{logging-2BXvW7Mp.js → logging-BfORLKoq.js} +1 -1
- package/dist/{message-BG1v1lXX.js → message-DqjuKzUx.js} +13 -23
- package/dist/nitro.d.ts +1 -1
- package/dist/nitro.js +3 -3
- package/dist/{oauth-callback-server-CXNZJymo.js → oauth-callback-server-CFSRzu1n.js} +2 -2
- package/dist/{projection-BfKkpOGQ.js → projection-DliWYrnT.js} +575 -74
- package/dist/{prompt-CCtaGgbI.js → prompt-BvIUzY4y.js} +8 -6
- package/dist/push-endpoint-CO-nomUd.js +36 -0
- package/dist/{registry-CLooHPAz.js → registry-rC7MCxu8.js} +1 -1
- package/dist/{reporting-window-B-QP9zX1.js → reporting-window-B4TwyuJo.js} +14 -14
- package/dist/{resolve-D3MK9oRJ.js → resolve-Biu8Qw3u.js} +3 -3
- package/dist/result-DxJMCX47.js +299 -0
- package/dist/result-event-type-DD6BAgT7.js +11 -0
- package/dist/{runner-Ds31u3rB.js → runner-BQJSFLKg.js} +11 -11
- package/dist/{sandbox-egress-signals-CLd5RPUw.js → sandbox-egress-signals-6aMxJSDn.js} +1 -1
- package/dist/{cadence-R7Em4RjE.js → schedule-BTp__wrw.js} +81 -1
- package/dist/{schema-jW3ccLjp.d.ts → schema-BUviRAs8.d.ts} +196 -220
- package/dist/{schema-CHNP0GfH.js → schema-BasXTvi2.js} +94 -5
- package/dist/{service-account-D6AMahy7.js → service-account-BI5Wgx22.js} +3 -3
- package/dist/{service-account-CWpTsoIM.js → service-account-CAE-_1dR.js} +3 -3
- package/dist/session-stop-CA-jOJ84.js +2924 -0
- package/dist/{skills-DuOKByQH.js → skills-B22duVJU.js} +2 -2
- package/dist/{spawn-CNIQGgAS.js → spawn-BB2_4VYn.js} +2 -2
- package/dist/{stop-DX2oOIgl.js → stop-DioIcEAu.js} +4830 -4200
- package/dist/{store-61mD4ZSh.js → store-B26LV6UP.js} +78 -311
- package/dist/{store-DAJntSEv.js → store-Dn4W7qgH.js} +30 -5
- package/dist/{task-queue-BE70Pb9p.js → task-queue-Bt0IoR2i.js} +3 -3
- package/dist/{task-runner-CmmfddSZ.js → task-runner-D8lddjzp.js} +17 -8
- package/dist/{thread-state-0UfRMWYd.js → thread-state-CrFk3K_7.js} +4 -4
- package/dist/{turn-failure-response-DKdzxJHE.js → turn-failure-response-DaJ04qVj.js} +7 -7
- package/dist/{turn-lifecycle-24sBZ4Ip.js → turn-lifecycle-C2mXS7AZ.js} +1 -1
- package/dist/{turn-session-routing-CzCnNAUO.js → turn-session-routing-CGMKrYOj.js} +10 -10
- package/dist/{validation-Cs_knhR8.js → validation-TzhfQABF.js} +1 -1
- package/dist/{version-ZMC4cXWN.js → version-DSk8CFvA.js} +1 -1
- package/dist/version.js +1 -1
- package/dist/{viewer-CYB9T4rm.js → viewer-1Ea81s0b.js} +190 -53
- package/dist/{work-J1n6RQkY.js → work-ybG4_q5C.js} +238 -32
- package/dist/{worker-s1fCvj1z.js → worker-ccSyZRNz.js} +6 -6
- package/migrations/0082_push_notifications.sql +14 -0
- package/migrations/0083_conversation_kind.sql +11 -0
- package/migrations/0084_read_position_backfill.sql +25 -0
- package/migrations/0085_child_archived_at.sql +1 -0
- package/migrations/meta/0082_snapshot.json +4373 -0
- package/migrations/meta/0083_snapshot.json +4388 -0
- package/migrations/meta/0084_snapshot.json +4388 -0
- package/migrations/meta/0085_snapshot.json +4394 -0
- package/migrations/meta/_journal.json +28 -0
- package/package.json +7 -5
- package/dist/result-BPCjUefO.js +0 -483
- package/dist/session-stop-D8LGC3H6.js +0 -1438
|
@@ -1,7 +1,9 @@
|
|
|
1
|
-
import {
|
|
2
|
-
import {
|
|
3
|
-
import "./
|
|
4
|
-
import "./
|
|
1
|
+
import { r as notificationScheduleSchema } from "./schedule-BTp__wrw.js";
|
|
2
|
+
import { D as conversationChildAgentTotalsSchema, S as conversationUsageSchema, b as conversationSummaryReportSchema, i as actorIdentitySchema, s as conversationAuxiliaryCostsSchema } from "./conversation-D8kVoCrP.js";
|
|
3
|
+
import { C as AGENT_INVOCATION_STATUSES, b as userInputRequestSchema, i as fillUtcHours, r as fillUtcDays, s as sumUtcHoursIntoSixHours } from "./reporting-window-B4TwyuJo.js";
|
|
4
|
+
import "./automation-Mk8aaHzy.js";
|
|
5
|
+
import "./conversation-pending-messages-BvROq1bq.js";
|
|
6
|
+
import { t as isPushServiceEndpoint } from "./push-endpoint-CO-nomUd.js";
|
|
5
7
|
import * as z from "zod";
|
|
6
8
|
import { codeChangeStateSchema, eventMatchSchema } from "@sentry/junior-plugin-api";
|
|
7
9
|
// src/api/schema/conversation-catch-up.ts
|
|
@@ -31,8 +33,23 @@ const pinConversationResponseSchema = z.object({ pinnedAt: z.string().datetime()
|
|
|
31
33
|
const reorderPinnedConversationsBodySchema = z.object({ conversationIds: z.array(z.string().min(1)).min(1).max(500).refine((ids) => new Set(ids).size === ids.length, { message: "Each Conversation can appear once." }) }).strict();
|
|
32
34
|
/** The pinned Conversations that got a new place, in order. */
|
|
33
35
|
const reorderPinnedConversationsResponseSchema = z.object({ conversationIds: z.array(z.string()) }).strict();
|
|
36
|
+
// src/api/schema/conversation-unread.ts
|
|
37
|
+
/** Mark one Conversation read or unread for the signed-in viewer. */
|
|
38
|
+
const markConversationUnreadBodySchema = z.object({ unread: z.boolean() }).strict();
|
|
39
|
+
/**
|
|
40
|
+
* Whether Junior's latest visible reply is after the viewer's read position
|
|
41
|
+
* once the change is stored.
|
|
42
|
+
*/
|
|
43
|
+
const conversationUnreadSchema = z.object({ unreadReply: z.boolean() }).strict();
|
|
34
44
|
// src/api/schema/conversation-archive.ts
|
|
45
|
+
/**
|
|
46
|
+
* Archive or restore one conversation. `applyToChildren` applies to a child
|
|
47
|
+
* only: archive refuses while a descendant is unarchived unless it is true,
|
|
48
|
+
* and restore also restores the descendants archived with the child when it
|
|
49
|
+
* is true. A root archive is per viewer and writes no child rows.
|
|
50
|
+
*/
|
|
35
51
|
const archiveConversationBodySchema = z.object({
|
|
52
|
+
applyToChildren: z.boolean().optional(),
|
|
36
53
|
archived: z.boolean(),
|
|
37
54
|
lastSeenAt: z.string().datetime()
|
|
38
55
|
}).strict();
|
|
@@ -41,6 +58,13 @@ const archiveConversationResponseSchema = z.object({ archivedAt: z.string().date
|
|
|
41
58
|
const conversationAutoArchiveSchema = z.object({ autoArchive: z.boolean() }).strict();
|
|
42
59
|
/** Result of archiving all of the viewer's done conversations once. */
|
|
43
60
|
const archiveDoneConversationsResponseSchema = z.object({ archived: z.number().int().nonnegative() }).strict();
|
|
61
|
+
// src/api/schema/conversation-title.ts
|
|
62
|
+
/** Longest Conversation title that a rename can save. */
|
|
63
|
+
const CONVERSATION_TITLE_MAX_LENGTH = 200;
|
|
64
|
+
/** A participant's new title for one Conversation. Every viewer sees it. */
|
|
65
|
+
const renameConversationBodySchema = z.object({ title: z.string().trim().min(1).max(200) }).strict();
|
|
66
|
+
/** The stored title after the rename. */
|
|
67
|
+
const renameConversationResponseSchema = z.object({ title: z.string().min(1) }).strict();
|
|
44
68
|
// src/api/schema/conversation-stats.ts
|
|
45
69
|
const conversationStatsItemSchema = z.object({
|
|
46
70
|
active: z.number(),
|
|
@@ -121,6 +145,15 @@ const stopConversationTurnResponseSchema = z.object({
|
|
|
121
145
|
stoppedInboundMessageIds: z.array(z.string().min(1)),
|
|
122
146
|
stoppedMessages: z.array(stoppedConversationMessageSchema)
|
|
123
147
|
}).strict();
|
|
148
|
+
// src/api/schema/conversation-continue-in-slack.ts
|
|
149
|
+
/** Public Slack channel Location that a dashboard Conversation moves to. */
|
|
150
|
+
const continueConversationInSlackBodySchema = z.object({ locationId: z.string().min(1) }).strict();
|
|
151
|
+
/** The Slack thread where the Conversation now continues. */
|
|
152
|
+
const continueConversationInSlackResponseSchema = z.object({
|
|
153
|
+
conversationId: z.string().min(1),
|
|
154
|
+
channelName: z.string().min(1).optional(),
|
|
155
|
+
locationUrl: z.string().url().optional()
|
|
156
|
+
}).strict();
|
|
124
157
|
// src/api/schema/child-agent.ts
|
|
125
158
|
/**
|
|
126
159
|
* One direct child agent of a Conversation, from agent invocation records.
|
|
@@ -128,6 +161,7 @@ const stopConversationTurnResponseSchema = z.object({
|
|
|
128
161
|
* Viewers who cannot see private content get the status, time, and usage, but
|
|
129
162
|
* not the name, task, title, or error. Usage covers the child Conversation and
|
|
130
163
|
* all its own child agents, like the detail of that child Conversation.
|
|
164
|
+
* Archived children stay in the report.
|
|
131
165
|
*/
|
|
132
166
|
const conversationChildAgentSchema = z.object({
|
|
133
167
|
auxiliaryCosts: conversationAuxiliaryCostsSchema.optional(),
|
|
@@ -136,10 +170,13 @@ const conversationChildAgentSchema = z.object({
|
|
|
136
170
|
cumulativeDurationMs: z.number(),
|
|
137
171
|
cumulativeUsage: conversationUsageSchema.optional(),
|
|
138
172
|
error: z.string().min(1).optional(),
|
|
173
|
+
kind: z.enum(["thread", "task"]),
|
|
139
174
|
name: z.string().min(1).optional(),
|
|
140
175
|
redacted: z.literal(true).optional(),
|
|
141
176
|
status: z.enum(AGENT_INVOCATION_STATUSES),
|
|
142
177
|
task: z.string().optional(),
|
|
178
|
+
/** When the child was archived for everyone, or null. */
|
|
179
|
+
childArchivedAt: z.string().datetime().nullable(),
|
|
143
180
|
title: z.string().min(1).optional(),
|
|
144
181
|
updatedAt: z.string().datetime()
|
|
145
182
|
}).strict().superRefine((data, context) => {
|
|
@@ -302,6 +339,35 @@ const connectionListSchema = z.object({ connections: z.array(connectionSchema) }
|
|
|
302
339
|
const connectionParamsSchema = z.object({ provider: z.string().regex(/^[a-z][a-z0-9-]*$/).max(64) }).strict();
|
|
303
340
|
const startConnectionResponseSchema = z.object({ authorizationUrl: z.string().url() }).strict();
|
|
304
341
|
const disconnectConnectionResponseSchema = z.object({ disconnected: z.literal(true) }).strict();
|
|
342
|
+
// src/api/schema/notification.ts
|
|
343
|
+
const notificationTimezoneSourceSchema = z.enum([
|
|
344
|
+
"manual",
|
|
345
|
+
"slack",
|
|
346
|
+
"saved",
|
|
347
|
+
"default"
|
|
348
|
+
]);
|
|
349
|
+
/** The viewer's phone notification settings. */
|
|
350
|
+
const notificationSettingsSchema = z.object({
|
|
351
|
+
/** Server VAPID public key. Absent when Web Push is not configured. */
|
|
352
|
+
publicKey: z.string().min(1).optional(),
|
|
353
|
+
schedule: notificationScheduleSchema,
|
|
354
|
+
/** Timezone that Junior uses for the schedule now. */
|
|
355
|
+
timezone: z.string().min(1),
|
|
356
|
+
timezoneSource: notificationTimezoneSourceSchema,
|
|
357
|
+
/** Number of browsers that receive the viewer's notifications. */
|
|
358
|
+
deviceCount: z.number().int().nonnegative()
|
|
359
|
+
}).strict();
|
|
360
|
+
/** `PushSubscription#toJSON()` from the browser. */
|
|
361
|
+
const pushSubscriptionBodySchema = z.object({
|
|
362
|
+
endpoint: z.string().max(2048).refine(isPushServiceEndpoint, "Unknown push service."),
|
|
363
|
+
expirationTime: z.number().nullable().optional(),
|
|
364
|
+
keys: z.object({
|
|
365
|
+
auth: z.string().min(1).max(256),
|
|
366
|
+
p256dh: z.string().min(1).max(256)
|
|
367
|
+
}).strict()
|
|
368
|
+
}).strict();
|
|
369
|
+
const pushSubscriptionDeleteBodySchema = z.object({ endpoint: z.string().url().max(2048) }).strict();
|
|
370
|
+
const testNotificationResponseSchema = z.object({ delivered: z.number().int().nonnegative() }).strict();
|
|
305
371
|
// src/api/activity.ts
|
|
306
372
|
const dailyConversationActivitySchema = z.object({
|
|
307
373
|
active: z.number(),
|
|
@@ -679,4 +745,27 @@ const statsReportSchema = z.object({
|
|
|
679
745
|
windowEnd: z.string(),
|
|
680
746
|
windowStart: z.string()
|
|
681
747
|
}).strict();
|
|
682
|
-
|
|
748
|
+
// src/api/schema/versions.ts
|
|
749
|
+
const versionsQuerySchema = z.object({
|
|
750
|
+
/** The open Conversation, whose token comes back as `conversation`. */
|
|
751
|
+
conversationId: z.string().min(1).optional() }).strict();
|
|
752
|
+
/**
|
|
753
|
+
* Opaque change tokens for the dashboard reads that refresh by themselves.
|
|
754
|
+
* A token changes when the read it covers can change. Compare a token only
|
|
755
|
+
* with an earlier token of the same field.
|
|
756
|
+
*/
|
|
757
|
+
const versionsSchema = z.object({
|
|
758
|
+
/**
|
|
759
|
+
* Tree token of the requested Conversation, the same value as the
|
|
760
|
+
* detail report's `CONVERSATION_VERSION_HEADER`. Missing when it does
|
|
761
|
+
* not exist.
|
|
762
|
+
*/
|
|
763
|
+
conversation: z.string().min(1).optional(),
|
|
764
|
+
/** The viewer's Conversation feed. */
|
|
765
|
+
conversations: z.string().min(1),
|
|
766
|
+
/** Open Review items that need the viewer. */
|
|
767
|
+
reviewItems: z.string().min(1),
|
|
768
|
+
/** The viewer's rolling model spend. */
|
|
769
|
+
spend: z.string().min(1)
|
|
770
|
+
}).strict();
|
|
771
|
+
export { codeChangeSummaryReportSchema as $, actorDirectoryReportSchema as A, activityHours as B, startServiceAccountSignInResponseSchema as C, pinConversationBodySchema as Ct, personalTokenMetadataSchema as D, conversationCatchUpBodySchema as Dt, personalTokenListSchema as E, reorderPinnedConversationsResponseSchema as Et, locationActivityDayReportSchema as F, pushSubscriptionDeleteBodySchema as G, dailyConversationActivitySchema as H, locationDetailReportSchema as I, connectionParamsSchema as J, testNotificationResponseSchema as K, locationDirectoryReportSchema as L, avatarParamsSchema as M, personParamsSchema as N, personalTokenParamsSchema as O, conversationCatchUpSchema as Ot, personalSpendReportSchema as P, codeActivityDaySchema as Q, locationParamsSchema as R, serviceAccountSchema as S, markConversationUnreadBodySchema as St, createdPersonalTokenSchema as T, reorderPinnedConversationsBodySchema as Tt, notificationSettingsSchema as U, activitySixHours as V, pushSubscriptionBodySchema as W, disconnectConnectionResponseSchema as X, connectionSchema as Y, startConnectionResponseSchema as Z, reviewItemSchema as _, archiveConversationBodySchema as _t, baselineSnapshotSchema as a, codeRepositorySummarySchema as at, serviceAccountListSchema as b, conversationAutoArchiveSchema as bt, workspaceListSchema as c, conversationChildAgentSchema as ct, workspaceSchema as d, continueConversationInSlackResponseSchema as dt, codeChangeSummarySchema as et, reviewItemActionSchema as f, stopConversationTurnResponseSchema as ft, reviewItemParamsSchema as g, renameConversationResponseSchema as gt, reviewItemListSchema as h, renameConversationBodySchema as ht, statsReportSchema as i, codeRepositoryReportSchema as it, actorProfileReportSchema as j, revokePersonalTokenResponseSchema as k, workspaceParamsSchema as l, conversationChildAgentsReportSchema as lt, reviewItemListQuerySchema as m, CONVERSATION_TITLE_MAX_LENGTH as mt, versionsSchema as n, codePersonReportSchema as nt, deleteWorkspaceResponseSchema as o, conversationWatchSchema as ot, reviewItemCountSchema as p, conversationStatsReportSchema as pt, connectionListSchema as q, statSchema as r, codeRepositoryParamsSchema as rt, workspaceBodySchema as s, conversationWatchesReportSchema as st, versionsQuerySchema as t, codeOverviewReportSchema as tt, workspaceRepoSchema as u, continueConversationInSlackBodySchema as ut, reviewItemWaitingConversationsSchema as v, archiveConversationResponseSchema as vt, createPersonalTokenBodySchema as w, pinConversationResponseSchema as wt, serviceAccountParamsSchema as x, conversationUnreadSchema as xt, disconnectServiceAccountResponseSchema as y, archiveDoneConversationsResponseSchema as yt, activityDays as z };
|
|
@@ -1,7 +1,7 @@
|
|
|
1
|
-
import { W as isRecord, b as setSpanAttributes, h as logWarn } from "./logging-
|
|
2
|
-
import { c as fetchWithBoundedOAuthErrorBodies, i as resolvePluginHeaderEnvRefs } from "./registry-
|
|
1
|
+
import { W as isRecord, b as setSpanAttributes, h as logWarn } from "./logging-BfORLKoq.js";
|
|
2
|
+
import { c as fetchWithBoundedOAuthErrorBodies, i as resolvePluginHeaderEnvRefs } from "./registry-rC7MCxu8.js";
|
|
3
3
|
import { a as withLock, i as fenceLock, n as MUTATION_LOCK_TTL_MS } from "./locks-D-0h111u.js";
|
|
4
|
-
import { r as getStateAdapter } from "./adapter-
|
|
4
|
+
import { r as getStateAdapter } from "./adapter-DN5AB4VU.js";
|
|
5
5
|
import { AsyncLocalStorage } from "node:async_hooks";
|
|
6
6
|
import { randomUUID } from "node:crypto";
|
|
7
7
|
import { UnauthorizedError, auth } from "@modelcontextprotocol/sdk/client/auth.js";
|
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
import { n as pluginCatalogRuntime } from "./catalog-runtime-
|
|
2
|
-
import { t as disconnectStateAdapter } from "./adapter-
|
|
3
|
-
import { n as finishServiceAccountSignIn, o as serviceAccountPlugins, r as getServiceAccountStatus, s as startServiceAccountSignIn, t as disconnectServiceAccount } from "./service-account-
|
|
1
|
+
import { n as pluginCatalogRuntime } from "./catalog-runtime-Bte6jRB2.js";
|
|
2
|
+
import { t as disconnectStateAdapter } from "./adapter-DN5AB4VU.js";
|
|
3
|
+
import { n as finishServiceAccountSignIn, o as serviceAccountPlugins, r as getServiceAccountStatus, s as startServiceAccountSignIn, t as disconnectServiceAccount } from "./service-account-BI5Wgx22.js";
|
|
4
4
|
import { CLI_USAGE } from "./cli/run.js";
|
|
5
5
|
import { createServer } from "node:http";
|
|
6
6
|
// src/cli/service-account.ts
|