@sentry/junior 0.248.0 → 0.250.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/{admin-BlHz8fGl.js → admin-DMKyXi83.js} +1 -1
- package/dist/{agent-hooks-DWCHBPYw.js → agent-hooks-CtZuJPTU.js} +26 -11
- package/dist/{agent-runner-CnlFtbzb.js → agent-runner-CNiTpIpb.js} +745 -423
- package/dist/api/schema.d.ts +33 -0
- package/dist/api/schema.js +4 -4
- package/dist/api.js +56 -24
- package/dist/app.js +36 -44
- package/dist/{assistant-reply-BxCi7V4v.js → assistant-reply-K5r1pcgJ.js} +1 -1
- package/dist/{briefs-CdkIl79U.js → briefs-8xyS3oeV.js} +4 -4
- package/dist/{catalog-runtime-CTBsdSam.js → catalog-runtime-BQ3g3OX_.js} +1 -1
- package/dist/cli/chat.js +15 -15
- package/dist/cli/check.js +3 -3
- package/dist/cli/main.js +2 -2
- package/dist/cli/plugins.js +4 -4
- package/dist/cli/snapshot-create.js +3 -3
- package/dist/cli/upgrade.js +3 -3
- package/dist/{client-CWQtbizj.js → client-Q27hki0Y.js} +2 -2
- package/dist/{config-aitDvTQm.js → config-Cb--Qs-g.js} +2 -2
- package/dist/{web-authorization-rDLlKIS0.js → connections-DZ70JeSN.js} +85 -8
- package/dist/{conversation-Cjo9tHGm.js → conversation-NutPJ8S8.js} +1 -1
- package/dist/{conversation-privacy-BsqXHVBz.js → conversation-privacy-BIDN1sW3.js} +1 -1
- package/dist/{credential-sync-DqZF735a.js → credential-sync-CyAN-Gos.js} +18 -23
- package/dist/{executor-oIZAkQZb.js → executor-D8y7v95s.js} +2 -2
- package/dist/{history-Nte1oVed.js → history-9pO1Zd4Y.js} +7 -1
- package/dist/{images-Dzh3RBXY.js → images-BkGhqKIK.js} +3 -3
- package/dist/instrumentation.js +2 -2
- package/dist/{job-queue-DyA2AEnY.js → job-queue-uGq6Grnt.js} +1 -1
- package/dist/{logging-OpC2jwiV.js → logging-C22RdmU8.js} +1 -1
- package/dist/{message-EyMrVXEf.js → message-D0RPetp-.js} +3 -3
- package/dist/nitro.js +3 -3
- package/dist/{oauth-callback-server-ClDv9Z5Y.js → oauth-callback-server-DF_Odkvh.js} +2 -2
- package/dist/{pending-auth-D_nf121N.js → pending-auth-Bg3A1-pE.js} +2 -2
- package/dist/{profile-Dfg76pvk.js → profile-DK9umvav.js} +4 -4
- package/dist/{prompt-C7bRJ2vg.js → prompt-kYP1FAX_.js} +1 -1
- package/dist/{registry-fpIZHoqE.js → registry-BvsLuoLK.js} +1 -1
- package/dist/{resolve-LMCZhQVg.js → resolve-C9btOXju.js} +2 -2
- package/dist/{result-C1ZCRPLx.js → result-CcdQ2iau.js} +8 -8
- package/dist/{runner-DNZMviFH.js → runner-Bem4DUHN.js} +10 -10
- package/dist/{sandbox-egress-signals-Dcc-mwkl.js → sandbox-egress-signals-Bl-4cF7E.js} +1 -1
- package/dist/{schema-BRZsYL5-.js → schema-DELmAdjR.js} +18 -2
- package/dist/{session-stop-dyvsZDB0.js → session-stop-DteRDRCi.js} +17 -14
- package/dist/{skills-BgGiQt5Y.js → skills-CVwSL6Gc.js} +2 -2
- package/dist/{spawn-CpqxMPWE.js → spawn-CA0YYtzr.js} +2 -2
- package/dist/{store-OMQAFrJG.js → store-Dw3eBN9S.js} +6 -6
- package/dist/{task-queue-SWsXPSp-.js → task-queue-C7cyjcVj.js} +3 -3
- package/dist/{task-runner-BOxv7shv.js → task-runner-BbSyWmOq.js} +11 -11
- package/dist/{tasks-DREdnhVP.js → tasks-B8nH3ND_.js} +10 -10
- package/dist/{thread-state-BoNCtSwk.js → thread-state-BTOLzCM-.js} +6 -6
- package/dist/{turn-failure-response-C6jrCPjc.js → turn-failure-response-BwNfO8Xt.js} +8 -8
- package/dist/{turn-lifecycle-cQFsZFOU.js → turn-lifecycle-DSN0xGW7.js} +1 -1
- package/dist/{turn-session-routing-Ba12fwXz.js → turn-session-routing-BRKYIn6n.js} +1 -1
- package/dist/{validation-Dmfh2cTj.js → validation-CBkyzKCP.js} +1 -1
- package/dist/{version-ByV7nGOn.js → version-CkwwLVLb.js} +1 -1
- package/dist/version.js +1 -1
- package/dist/{viewer-CX41TWYr.js → viewer-DdzigZQh.js} +4 -4
- package/dist/{web-input-Bn9HHZEo.js → web-input-BjdnnpuN.js} +29 -29
- package/dist/{work-CvFoEpRT.js → work-qQEjtmlv.js} +29 -13
- package/dist/{worker-CI5B63vk.js → worker-C-CSZMy_.js} +5 -5
- package/package.json +4 -4
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { a as setUserAdminFromSql, d as getDb, n as listAdminUsersFromSql } from "./viewer-
|
|
1
|
+
import { a as setUserAdminFromSql, d as getDb, n as listAdminUsersFromSql } from "./viewer-DdzigZQh.js";
|
|
2
2
|
import { CLI_USAGE } from "./cli/run.js";
|
|
3
3
|
//#region src/cli/admin.ts
|
|
4
4
|
/**
|
|
@@ -1,20 +1,20 @@
|
|
|
1
1
|
import { t as __exportAll } from "./rolldown-runtime-B4FMCO8f.js";
|
|
2
|
-
import { a as embedTexts, r as completeObject } from "./client-
|
|
3
|
-
import { I as isRecord$1, a as extractGenAiUsageSummary, d as logException, f as logInfo, p as logWarn, v as setSpanAttributes, w as withSpan, y as setSpanStatus } from "./logging-
|
|
2
|
+
import { a as embedTexts, r as completeObject } from "./client-Q27hki0Y.js";
|
|
3
|
+
import { I as isRecord$1, a as extractGenAiUsageSummary, d as logException, f as logInfo, p as logWarn, v as setSpanAttributes, w as withSpan, y as setSpanStatus } from "./logging-C22RdmU8.js";
|
|
4
4
|
import { a as getClient$1 } from "./sentry-CgWZM_kV.js";
|
|
5
|
-
import { t as canExposeConversationPayload } from "./conversation-privacy-
|
|
6
|
-
import { i as getChatConfig, n as botConfig, o as getSlackBotToken } from "./config-
|
|
5
|
+
import { t as canExposeConversationPayload } from "./conversation-privacy-BIDN1sW3.js";
|
|
6
|
+
import { i as getChatConfig, n as botConfig, o as getSlackBotToken } from "./config-Cb--Qs-g.js";
|
|
7
7
|
import { r as defaultModelId } from "./model-profile-BwU8mqwD.js";
|
|
8
8
|
import { d as parseSlackTeamId, g as parseSlackMessageTs, i as isActorUserId, o as parseActorUserId, u as parseSlackChannelReferenceId } from "./actor-BTtLaeWy.js";
|
|
9
|
-
import { O as readUserTimezone, T as hasAgentTurnUsage, c as getConversationEventStore, d as getDb, f as getSqlExecutor, h as createSqlStore, i as resolveViewerUser, k as saveUserTimezone, r as readActorIdentity } from "./viewer-
|
|
9
|
+
import { O as readUserTimezone, T as hasAgentTurnUsage, c as getConversationEventStore, d as getDb, f as getSqlExecutor, h as createSqlStore, i as resolveViewerUser, k as saveUserTimezone, r as readActorIdentity } from "./viewer-DdzigZQh.js";
|
|
10
10
|
import { c as juniorIdentities, d as juniorDestinations, l as juniorUsers, s as juniorConversations } from "./agent-invocations-D_YoNnAn.js";
|
|
11
|
-
import { S as juniorAttachments, _ as juniorConversationEvents, b as juniorCodeChanges, f as juniorConversationParticipants, i as juniorWorkspaces, m as juniorConversationBriefs, n as juniorSnapshots, r as juniorWorkspaceRepos, x as juniorCodeRepositories, y as juniorConversationAnnotations } from "./executor-
|
|
12
|
-
import { o as decodeStoredConversationEvent } from "./history-
|
|
13
|
-
import { p as credentialSubjectSchema } from "./registry-
|
|
14
|
-
import { C as conversationReportEventSchema, F as readMessageAttachments, H as conversationBriefSchema, U as parseBriefInput, q as readMessageCardRefs } from "./conversation-
|
|
15
|
-
import { C as getDefaultRedisStateAdapterFor, N as SANDBOX_WORKSPACE_ROOT, k as sleep$1, l as isSandboxMissingError, n as hash, v as getVercelSandboxCredentials, w as getStateAdapter, x as runNonInteractiveCommand } from "./profile-
|
|
11
|
+
import { S as juniorAttachments, _ as juniorConversationEvents, b as juniorCodeChanges, f as juniorConversationParticipants, i as juniorWorkspaces, m as juniorConversationBriefs, n as juniorSnapshots, r as juniorWorkspaceRepos, x as juniorCodeRepositories, y as juniorConversationAnnotations } from "./executor-D8y7v95s.js";
|
|
12
|
+
import { o as decodeStoredConversationEvent } from "./history-9pO1Zd4Y.js";
|
|
13
|
+
import { p as credentialSubjectSchema } from "./registry-BvsLuoLK.js";
|
|
14
|
+
import { C as conversationReportEventSchema, F as readMessageAttachments, H as conversationBriefSchema, U as parseBriefInput, q as readMessageCardRefs } from "./conversation-NutPJ8S8.js";
|
|
15
|
+
import { C as getDefaultRedisStateAdapterFor, N as SANDBOX_WORKSPACE_ROOT, k as sleep$1, l as isSandboxMissingError, n as hash, v as getVercelSandboxCredentials, w as getStateAdapter, x as runNonInteractiveCommand } from "./profile-DK9umvav.js";
|
|
16
16
|
import { i as isValidTimeZone } from "./cadence-D00SCzT1.js";
|
|
17
|
-
import { n as briefEntriesFromReportEvents, s as generateBrief, t as BRIEF_PROMPT } from "./prompt-
|
|
17
|
+
import { n as briefEntriesFromReportEvents, s as generateBrief, t as BRIEF_PROMPT } from "./prompt-kYP1FAX_.js";
|
|
18
18
|
import { AsyncLocalStorage } from "node:async_hooks";
|
|
19
19
|
import { z } from "zod";
|
|
20
20
|
import { createHash, createHmac, randomUUID, timingSafeEqual } from "node:crypto";
|
|
@@ -2452,6 +2452,8 @@ const subscriptionSchema = z.object({
|
|
|
2452
2452
|
events: z.array(eventTypeSchema).min(1),
|
|
2453
2453
|
expiresAtMs: z.number().finite(),
|
|
2454
2454
|
firesAtMs: z.number().finite().optional(),
|
|
2455
|
+
/** Guidance for this Watch only, by event type. */
|
|
2456
|
+
guidance: z.record(eventTypeSchema, z.string().min(1)).optional(),
|
|
2455
2457
|
id: z.string().min(1),
|
|
2456
2458
|
intent: z.string().min(1),
|
|
2457
2459
|
label: z.string().min(1),
|
|
@@ -2572,6 +2574,16 @@ function activeAt(subscription, nowMs) {
|
|
|
2572
2574
|
function matchesEvent(subscription, input) {
|
|
2573
2575
|
return subscription.namespace === input.namespace && subscription.identifier === input.identifier && subscription.events.includes(input.eventType) && activeAt(subscription, input.nowMs) && eventMatches(subscription.match, input.data);
|
|
2574
2576
|
}
|
|
2577
|
+
/** Keep non-empty guidance for events that the Watch receives. */
|
|
2578
|
+
function watchGuidance(guidance, events) {
|
|
2579
|
+
if (!guidance) return void 0;
|
|
2580
|
+
const kept = {};
|
|
2581
|
+
for (const eventType of events) {
|
|
2582
|
+
const text = guidance[eventType]?.trim();
|
|
2583
|
+
if (text) kept[eventType] = text;
|
|
2584
|
+
}
|
|
2585
|
+
return Object.keys(kept).length > 0 ? kept : void 0;
|
|
2586
|
+
}
|
|
2575
2587
|
/** Create or replace the active subscription for one conversation/resource/event set. */
|
|
2576
2588
|
async function createWatch(input, options = {}) {
|
|
2577
2589
|
const state = options.state ?? getStateAdapter();
|
|
@@ -2588,11 +2600,13 @@ async function createWatch(input, options = {}) {
|
|
|
2588
2600
|
namespace: input.namespace,
|
|
2589
2601
|
identifier: input.identifier
|
|
2590
2602
|
});
|
|
2603
|
+
const guidance = watchGuidance(input.guidance, events);
|
|
2591
2604
|
const record = {
|
|
2592
2605
|
conversationId: input.conversationId,
|
|
2593
2606
|
createdAtMs: nowMs,
|
|
2594
2607
|
events,
|
|
2595
2608
|
expiresAtMs: input.expiresAtMs,
|
|
2609
|
+
...guidance ? { guidance } : void 0,
|
|
2596
2610
|
id,
|
|
2597
2611
|
intent: input.intent,
|
|
2598
2612
|
label: input.label,
|
|
@@ -3726,6 +3740,7 @@ function getPluginTools(context, sandbox = createSandboxCapability(context.works
|
|
|
3726
3740
|
conversationId: context.conversationId,
|
|
3727
3741
|
events: input.events,
|
|
3728
3742
|
expiresAtMs: Date.now() + RESOURCE_SUBSCRIPTION_DEFAULT_TTL_MS,
|
|
3743
|
+
guidance: input.guidance,
|
|
3729
3744
|
intent: input.intent,
|
|
3730
3745
|
label: input.resource.label,
|
|
3731
3746
|
namespace: pluginName,
|