@sentry/junior 0.268.0 → 0.270.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/README.md +2 -9
- package/dist/{adapter-04AcD2SO.js → adapter-BQNTKVTF.js} +3 -49
- package/dist/{admin-DIU1QyG3.js → admin-CKVEoXa4.js} +1 -1
- package/dist/{agent-runner-CAYfFmU7.js → agent-runner-MSQSMFkq.js} +4538 -3251
- package/dist/api/schema.d.ts +2 -3
- package/dist/api/schema.js +7 -7
- package/dist/api.d.ts +3 -1
- package/dist/api.js +190 -301
- package/dist/{app-z6Uuyq3j.d.ts → app-Bz8t4P8p.d.ts} +9 -3
- package/dist/app.d.ts +1 -1
- package/dist/app.js +129 -209
- package/dist/{automation-CmeFBSEh.js → automation-Dwh_xcqM.js} +74 -74
- package/dist/{briefs-DQbV2jNr.js → briefs-DNFzFFVx.js} +5 -5
- package/dist/{catalog-runtime-BD9GSpc6.js → catalog-runtime-Bdym_wKy.js} +1 -1
- package/dist/cli/chat.js +16 -26
- package/dist/cli/check.js +3 -3
- package/dist/cli/main.js +5 -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 +3 -3
- package/dist/{client-C1yDYjoS.js → client-B2MjENki.js} +31 -16
- package/dist/{config-DrTeF80T.js → config-Dm3pWRqY.js} +3 -3
- package/dist/{connections-D46f8vvi.js → connections-0BBhiD-p.js} +10 -10
- package/dist/{conversation-DSo310Ps.js → conversation-AhOVzN_k.js} +11 -86
- package/dist/{conversation-privacy-CxlOCiUo.js → conversation-privacy-C1pJ89rs.js} +1 -1
- package/dist/{credential-sync-sm9fegLY.js → credential-sync-BRiWYs6_.js} +15 -14
- package/dist/{credentialed-lukuD-cc.js → credentialed-BeBaJMZ_.js} +565 -83
- package/dist/{store-xMuuXRE0.d.ts → db-BYOuu6v2.d.ts} +4 -0
- package/dist/{executor-4vhvsMZJ.js → executor-BB6eJkD4.js} +6 -6
- package/dist/instrumentation.js +2 -2
- package/dist/{interruption-marker-CkncDT8d.js → interruption-marker-CdblrIQK.js} +1 -1
- package/dist/{job-queue-In9QKz-I.js → job-queue-DiaXoSDg.js} +2 -2
- package/dist/{list-BkgnXEEB.js → list-BTDRxkOg.js} +331 -662
- package/dist/locks-D-0h111u.js +48 -0
- package/dist/{logging-DLSpkSSr.js → logging-C6EdT6PP.js} +1 -1
- package/dist/{history-C84mlAwO.js → media-U6Tuz6Mi.js} +84 -2
- package/dist/{message-BObyg59s.js → message-DsjiWRVg.js} +4 -4
- package/dist/{model-profile-Bg8EoCKD.js → model-profile-B998sjVd.js} +9 -2
- package/dist/nitro.d.ts +1 -1
- package/dist/nitro.js +5 -3
- package/dist/{oauth-callback-server-B-WbSdoH.js → oauth-callback-server-CjFFVGqa.js} +2 -2
- package/dist/{prompt-BW9jFsqZ.js → prompt-BPSdXYXV.js} +1 -1
- package/dist/{registry-BgecKva0.js → registry-CndmkP2P.js} +1 -1
- package/dist/reporting-schema-CZREhYc-.js +104 -0
- package/dist/{web-message-id-DlHNANtd.js → reporting-window-DRCi1Ls_.js} +139 -7
- package/dist/{resolve-Cpa4Bu1O.js → resolve-BkAA1wH7.js} +3 -3
- package/dist/{result-D3TSmZZ8.js → result-9TJTpuYP.js} +30 -11
- package/dist/{runner-DS5OKhEp.js → runner-BmKLSyJm.js} +12 -11
- package/dist/{sandbox-egress-signals-CnDjY5rx.js → sandbox-egress-signals-CjLaogMo.js} +1 -1
- package/dist/{schema-0050HFnB.js → schema-DNLJ_MzW.js} +36 -20
- package/dist/{schema-ZngqcOWM.d.ts → schema-WayPSHFu.d.ts} +149 -12
- package/dist/{service-account-CKV2WTY7.js → service-account-D6e9cVmH.js} +4 -3
- package/dist/{service-account-DGjnDw9y.js → service-account-DlhYl-Mu.js} +3 -3
- package/dist/{session-stop-Dam1EI7B.js → session-stop-MZRgYqYH.js} +24 -16
- package/dist/{skills-CfAnfImD.js → skills-BggTR_ue.js} +2 -2
- package/dist/{spawn-cmq9p4Ly.js → spawn-DmtlcAT_.js} +2 -2
- package/dist/{store-zPEoJPBB.js → store-BeWGgaMA.js} +3 -3
- package/dist/{store-C5PN02QO.js → store-Byarin7b.js} +4 -4
- package/dist/{task-queue-_mf28dSu.js → task-queue-Dt1_ZoI_.js} +3 -3
- package/dist/task-runner-DyKqAPpm.js +269 -0
- package/dist/{thread-state-BbbPh0Sn.js → thread-state-BHBLMvgb.js} +5 -5
- package/dist/{turn-failure-response-BKKmnMB5.js → turn-failure-response-DWXy_0oJ.js} +9 -9
- package/dist/{turn-lifecycle-oP0kVeGz.js → turn-lifecycle-AiXkVqCB.js} +1 -1
- package/dist/{tasks-SB9z-VTU.js → turn-session-routing-B9KLBhaT.js} +939 -120
- package/dist/{validation--JsAGLwc.js → validation-BW60Vtx_.js} +1 -1
- package/dist/{version-jHwJp4hC.js → version-CivPYmkH.js} +1 -1
- package/dist/version.js +1 -1
- package/dist/{viewer-CpXTGlep.js → viewer-BTgAfdUg.js} +216 -27
- package/dist/{work-3N-GHY9m.js → work-Bjm52fHo.js} +17 -36
- package/dist/{worker-CCdbcItd.js → worker-CMbgtHLu.js} +15 -7
- package/migrations/0069_system_identity.sql +25 -0
- package/migrations/0070_review_item_foreign_keys.sql +5 -0
- package/migrations/AGENTS.md +17 -0
- package/migrations/meta/0069_snapshot.json +3979 -0
- package/migrations/meta/0070_snapshot.json +3997 -0
- package/migrations/meta/_journal.json +15 -1
- package/package.json +5 -4
- package/dist/db-BU4LQD8s.d.ts +0 -6
- package/dist/history-BgI33Kie.d.ts +0 -78
- package/dist/reporting-window-DVCD_10C.js +0 -227
- package/dist/task-runner-DMI2prDO.js +0 -1073
- package/migrations/README.md +0 -30
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import { c as conversationTurnFailureReasonSchema, s as conversationTurnFailureCodeSchema, t as INPUT_IMAGE_TYPES, v as usageSchema } from "./media-U6Tuz6Mi.js";
|
|
2
2
|
import { z } from "zod";
|
|
3
3
|
import { codeChangeStateSchema, conversationAnnotationInputSchema, conversationEventPresentationSchema, conversationSidebarAnnotationSchema, objectFactFields, objectTypeSchema } from "@sentry/junior-plugin-api";
|
|
4
4
|
// src/chat/briefs/schema.ts
|
|
@@ -118,88 +118,6 @@ function parseBriefInput(input) {
|
|
|
118
118
|
entries: [...parsed.entries].sort((left, right) => left.index - right.index || left.createdAtMs - right.createdAtMs)
|
|
119
119
|
};
|
|
120
120
|
}
|
|
121
|
-
// src/chat/attachments/media.ts
|
|
122
|
-
const INPUT_IMAGE_TYPES = [
|
|
123
|
-
"image/png",
|
|
124
|
-
"image/jpeg",
|
|
125
|
-
"image/gif",
|
|
126
|
-
"image/webp"
|
|
127
|
-
];
|
|
128
|
-
/** Leading bytes of each accepted image type. `null` matches any byte. */
|
|
129
|
-
const IMAGE_SIGNATURES = [
|
|
130
|
-
{
|
|
131
|
-
mediaType: "image/png",
|
|
132
|
-
bytes: [
|
|
133
|
-
137,
|
|
134
|
-
80,
|
|
135
|
-
78,
|
|
136
|
-
71,
|
|
137
|
-
13,
|
|
138
|
-
10,
|
|
139
|
-
26,
|
|
140
|
-
10
|
|
141
|
-
]
|
|
142
|
-
},
|
|
143
|
-
{
|
|
144
|
-
mediaType: "image/jpeg",
|
|
145
|
-
bytes: [
|
|
146
|
-
255,
|
|
147
|
-
216,
|
|
148
|
-
255
|
|
149
|
-
]
|
|
150
|
-
},
|
|
151
|
-
{
|
|
152
|
-
mediaType: "image/gif",
|
|
153
|
-
bytes: [
|
|
154
|
-
71,
|
|
155
|
-
73,
|
|
156
|
-
70,
|
|
157
|
-
56,
|
|
158
|
-
55,
|
|
159
|
-
97
|
|
160
|
-
]
|
|
161
|
-
},
|
|
162
|
-
{
|
|
163
|
-
mediaType: "image/gif",
|
|
164
|
-
bytes: [
|
|
165
|
-
71,
|
|
166
|
-
73,
|
|
167
|
-
70,
|
|
168
|
-
56,
|
|
169
|
-
57,
|
|
170
|
-
97
|
|
171
|
-
]
|
|
172
|
-
},
|
|
173
|
-
{
|
|
174
|
-
mediaType: "image/webp",
|
|
175
|
-
bytes: [
|
|
176
|
-
82,
|
|
177
|
-
73,
|
|
178
|
-
70,
|
|
179
|
-
70,
|
|
180
|
-
null,
|
|
181
|
-
null,
|
|
182
|
-
null,
|
|
183
|
-
null,
|
|
184
|
-
87,
|
|
185
|
-
69,
|
|
186
|
-
66,
|
|
187
|
-
80
|
|
188
|
-
]
|
|
189
|
-
}
|
|
190
|
-
];
|
|
191
|
-
/**
|
|
192
|
-
* Detect an accepted image type from file bytes. Use this instead of a file
|
|
193
|
-
* name or declared content type, which can be wrong.
|
|
194
|
-
*/
|
|
195
|
-
function detectImageMediaType(data) {
|
|
196
|
-
return IMAGE_SIGNATURES.find(({ bytes }) => data.length >= bytes.length && bytes.every((byte, index) => byte === null || data[index] === byte))?.mediaType;
|
|
197
|
-
}
|
|
198
|
-
/** Report whether a media type is a raster image accepted by vision models. */
|
|
199
|
-
function isVisionImageMediaType(mediaType) {
|
|
200
|
-
const normalized = mediaType.split(";", 1)[0]?.trim().toLowerCase();
|
|
201
|
-
return normalized ? INPUT_IMAGE_TYPES.some((type) => type === normalized) : false;
|
|
202
|
-
}
|
|
203
121
|
// src/chat/attachments/input.ts
|
|
204
122
|
/** Bound JSON image input below the hosting platform's request size limit. */
|
|
205
123
|
const MAX_INPUT_IMAGE_BYTES = 3145728;
|
|
@@ -372,6 +290,11 @@ const acceptedConversationMessageSchema = z.object({
|
|
|
372
290
|
status: z.enum(["accepted", "duplicate"])
|
|
373
291
|
}).strict();
|
|
374
292
|
const actorIdentitySchema = z.object({
|
|
293
|
+
/**
|
|
294
|
+
* Junior API path of the profile photo: the person's Slack photo, then
|
|
295
|
+
* their Google photo.
|
|
296
|
+
*/
|
|
297
|
+
avatarUrl: z.string().optional(),
|
|
375
298
|
email: z.string().optional(),
|
|
376
299
|
fullName: z.string().optional(),
|
|
377
300
|
slackUserId: z.string().optional(),
|
|
@@ -390,6 +313,8 @@ const conversationPendingMessageSchema = z.object({
|
|
|
390
313
|
role: z.literal("user"),
|
|
391
314
|
source: z.enum(["slack", "web"]),
|
|
392
315
|
text: z.string().optional(),
|
|
316
|
+
/** People mentioned in the text, resolved at read time. */
|
|
317
|
+
mentions: z.array(actorIdentitySchema).optional(),
|
|
393
318
|
attachments: z.array(messageAttachmentSchema).optional(),
|
|
394
319
|
redacted: z.literal(true).optional()
|
|
395
320
|
}).strict().superRefine((data, context) => {
|
|
@@ -397,9 +322,9 @@ const conversationPendingMessageSchema = z.object({
|
|
|
397
322
|
code: "custom",
|
|
398
323
|
message: "pending message content must be text or explicitly redacted"
|
|
399
324
|
});
|
|
400
|
-
if (data.redacted && (data.actorIdentity || data.attachments)) context.addIssue({
|
|
325
|
+
if (data.redacted && (data.actorIdentity || data.attachments || data.mentions)) context.addIssue({
|
|
401
326
|
code: "custom",
|
|
402
|
-
message: "redacted pending messages must not expose actor identity or
|
|
327
|
+
message: "redacted pending messages must not expose actor identity, attachments, or mentions"
|
|
403
328
|
});
|
|
404
329
|
});
|
|
405
330
|
/** Participant-only authorization prompt for a parked web turn. */
|
|
@@ -920,4 +845,4 @@ const conversationFeedSchema = z.object({
|
|
|
920
845
|
source: z.literal("conversation_index"),
|
|
921
846
|
generatedAt: z.string()
|
|
922
847
|
}).strict();
|
|
923
|
-
export { createConversationMessageBodySchema as A, removedCardSchema as B, conversationReportEventSchema as C, conversationSurfaceSchema as D, conversationSummaryReportSchema as E, conversationChildAgentTotalsSchema as F,
|
|
848
|
+
export { createConversationMessageBodySchema as A, removedCardSchema as B, conversationReportEventSchema as C, conversationSurfaceSchema as D, conversationSummaryReportSchema as E, conversationChildAgentTotalsSchema as F, briefCodeChangeSchema as G, MAX_INPUT_IMAGES as H, annotationCard as I, conversationBriefSchema as J, briefLinkSchema as K, messageCardRef as L, forkConversationResponseSchema as M, steerConversationPendingMessagesBodySchema as N, conversationUsageSchema as O, steerConversationPendingMessagesResponseSchema as P, messageCardText as R, conversationReportEventDataSchema as S, conversationReportStatusSchema as T, MAX_INPUT_IMAGE_BYTES as U, resolveMessageCards as V, readMessageAttachments as W, parseBriefInput as Y, conversationParamsSchema as _, cancelConversationPendingMessagesBodySchema as a, conversationPendingMessageSchema as b, conversationAttachmentParamsSchema as c, conversationDetailReportSchema as d, conversationEventHistorySchema as f, conversationFeedSchema as g, conversationFeedQuerySchema as h, archiveConversationResponseSchema as i, forkConversationBodySchema as j, createConversationBodySchema as k, conversationAuxiliaryCostsSchema as l, conversationEventsQuerySchema as m, actorIdentitySchema as n, cancelConversationPendingMessagesResponseSchema as o, conversationEventPageSchema as p, briefOutcomeStatusSchema as q, archiveConversationBodySchema as r, conversationActivityPreviewSchema as s, acceptedConversationMessageSchema as t, conversationDetailQuerySchema as u, conversationPendingAuthorizationSchema as v, conversationReportMessageEventSchema as w, conversationPendingMessagesReportSchema as x, conversationPendingMessageDeliverySchema as y, readMessageCardRefs as z };
|
|
@@ -1,19 +1,20 @@
|
|
|
1
|
-
import {
|
|
2
|
-
import { p as escapeXml } from "./client-
|
|
3
|
-
import { a as getRuntimeMetadata, n as botConfig } from "./config-
|
|
4
|
-
import { R as isNativeIdentityProvider, _ as runBestEffort, h as logWarn, p as logException } from "./logging-
|
|
1
|
+
import { It as recordAuthenticationLinked, Lt as recordAuthorizationCompleted, On as getTurnRecord, bn as getConversationPendingAuth } from "./turn-session-routing-B9KLBhaT.js";
|
|
2
|
+
import { p as escapeXml } from "./client-B2MjENki.js";
|
|
3
|
+
import { a as getRuntimeMetadata, n as botConfig } from "./config-Dm3pWRqY.js";
|
|
4
|
+
import { R as isNativeIdentityProvider, _ as runBestEffort, h as logWarn, p as logException } from "./logging-C6EdT6PP.js";
|
|
5
5
|
import { p as parseSlackUserId } from "./actor-CP9K2Idu.js";
|
|
6
|
-
import {
|
|
6
|
+
import { B as upsertLinkedIdentity, C as getSqlExecutor, I as findUserByVerifiedEmails, M as resolveActorIdentityId, o as readIdentityById } from "./viewer-BTgAfdUg.js";
|
|
7
7
|
import { i as homeDir } from "./package-discovery-DJBompdd.js";
|
|
8
|
-
import { n as buildOAuthTokenRequest, r as parseOAuthTokenResponse, u as hasRequiredOAuthScope } from "./registry-
|
|
9
|
-
import { n as pluginCatalogRuntime } from "./catalog-runtime-
|
|
10
|
-
import { t as discoverSkills } from "./skills-
|
|
11
|
-
import { a as finalizeMcpAuthorization, d as getMcpStoredOAuthCredentials, f as putMcpStoredOAuthCredentials, o as deleteMcpAuthSession, u as getMcpAuthSession, v as lookupSlackUserProfile } from "./agent-runner-
|
|
12
|
-
import {
|
|
13
|
-
import {
|
|
14
|
-
import {
|
|
15
|
-
import {
|
|
16
|
-
import {
|
|
8
|
+
import { n as buildOAuthTokenRequest, r as parseOAuthTokenResponse, u as hasRequiredOAuthScope } from "./registry-CndmkP2P.js";
|
|
9
|
+
import { n as pluginCatalogRuntime } from "./catalog-runtime-Bdym_wKy.js";
|
|
10
|
+
import { t as discoverSkills } from "./skills-BggTR_ue.js";
|
|
11
|
+
import { a as finalizeMcpAuthorization, d as getMcpStoredOAuthCredentials, f as putMcpStoredOAuthCredentials, o as deleteMcpAuthSession, u as getMcpAuthSession, v as lookupSlackUserProfile } from "./agent-runner-MSQSMFkq.js";
|
|
12
|
+
import { Dn as getSlackClient, Et as postSlackMessage, dt as parseOAuthStatePayload, ft as resolveBaseUrl, i as resolvePluginOAuthAccount, n as createUserTokenStore, ut as formatProviderLabel } from "./credentialed-BeBaJMZ_.js";
|
|
13
|
+
import { r as acquireActiveLock } from "./locks-D-0h111u.js";
|
|
14
|
+
import { r as getStateAdapter } from "./adapter-BQNTKVTF.js";
|
|
15
|
+
import { _ as getMcpProviderErrorAttributes } from "./service-account-D6e9cVmH.js";
|
|
16
|
+
import { o as coerceThreadConversationState, r as getPersistedThreadState } from "./thread-state-BHBLMvgb.js";
|
|
17
|
+
import { c as deleteWebAuthorization, i as readConnectedOAuthTokens, m as wakePausedTurn, p as wakeAuthorizedTurn, u as htmlCallbackResponse } from "./connections-0BBhiD-p.js";
|
|
17
18
|
import { n as relayLocalOAuthCallback } from "./oauth-relay-CTygMkNx.js";
|
|
18
19
|
import path from "node:path";
|
|
19
20
|
import { z } from "zod";
|