@sentry/junior 0.255.0 → 0.256.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 (53) hide show
  1. package/dist/{admin-CeJh4SuR.js → admin-BhucwVfy.js} +1 -1
  2. package/dist/{agent-hooks-CDVx26Uu.js → agent-hooks-DlSK8PQQ.js} +8 -8
  3. package/dist/{agent-runner-Caiof09f.js → agent-runner-C6_cd61V.js} +19 -19
  4. package/dist/api.js +21 -21
  5. package/dist/app.js +27 -27
  6. package/dist/{assistant-reply-BddmM66R.js → assistant-reply-yn5G-YEG.js} +1 -1
  7. package/dist/{briefs-iVq_8-ft.js → briefs-U6Bi3IYw.js} +2 -2
  8. package/dist/{catalog-runtime-hKmI-iZa.js → catalog-runtime-DF5OWqCc.js} +1 -1
  9. package/dist/cli/chat.js +15 -15
  10. package/dist/cli/check.js +3 -3
  11. package/dist/cli/main.js +2 -2
  12. package/dist/cli/plugins.js +4 -4
  13. package/dist/cli/snapshot-create.js +3 -3
  14. package/dist/cli/upgrade.js +3 -3
  15. package/dist/{client-Clj7onnT.js → client-BVrAp-pq.js} +2 -2
  16. package/dist/{config-BDAfLTI9.js → config-DdBiDanf.js} +2 -2
  17. package/dist/{connections-BC0RTejT.js → connections-CG04HdpC.js} +9 -9
  18. package/dist/{conversation-privacy-1ERtieuM.js → conversation-privacy-CpSYOWnP.js} +1 -1
  19. package/dist/{credential-sync-BZuqqIHk.js → credential-sync-DKWNdcgm.js} +14 -14
  20. package/dist/{executor-Dh4Ofsnx.js → executor-BroK9oKy.js} +2 -2
  21. package/dist/{images-C-WOnTc_.js → images-D0VZ5nv0.js} +2 -2
  22. package/dist/instrumentation.js +2 -2
  23. package/dist/{job-queue-BaCL36FY.js → job-queue-BbGg3gvu.js} +1 -1
  24. package/dist/{logging-D3aYP0aG.js → logging-tPQeUe2i.js} +1 -1
  25. package/dist/{message-B9xqD2BP.js → message-DdPGRYQP.js} +3 -3
  26. package/dist/nitro.js +3 -3
  27. package/dist/{oauth-callback-server-i5qdAou6.js → oauth-callback-server-B-2errCX.js} +2 -2
  28. package/dist/{pending-auth-D2t1Moxf.js → pending-auth-DT3MRVW8.js} +2 -2
  29. package/dist/{profile-DnkX3e2S.js → profile-Bb1zCVGP.js} +4 -4
  30. package/dist/{registry-CmKmKHpp.js → registry-CsNavQ_Z.js} +1 -1
  31. package/dist/{resolve-jfNHtEBx.js → resolve-B6ZZ9duG.js} +2 -2
  32. package/dist/{result-Df5nEDX2.js → result-j9nS0se-.js} +6 -6
  33. package/dist/{runner-CmzoXEI4.js → runner-Y331DoZ5.js} +9 -9
  34. package/dist/{sandbox-egress-signals-DjMNKLZz.js → sandbox-egress-signals-BUfjEdHY.js} +1 -1
  35. package/dist/{session-stop-BEBfE97J.js → session-stop-q-6GNHx6.js} +10 -10
  36. package/dist/{skills-Dc-AMYi4.js → skills-CyvTsR9M.js} +2 -2
  37. package/dist/{spawn-OgTwBUj0.js → spawn-Do5mX3d_.js} +2 -2
  38. package/dist/{store-BashBewg.js → store-D2It0ozF.js} +6 -6
  39. package/dist/{task-queue-VvIKqlQ4.js → task-queue-ZMk9bLRT.js} +3 -3
  40. package/dist/{task-runner-D2CpD6GN.js → task-runner-cIGU5VwJ.js} +10 -10
  41. package/dist/{tasks-dJooqiip.js → tasks-CODtRzvX.js} +8 -8
  42. package/dist/{thread-state-CsMC-ob0.js → thread-state-BPkwVmvK.js} +6 -6
  43. package/dist/{turn-failure-response-zB364t7_.js → turn-failure-response-ChmMeKar.js} +7 -7
  44. package/dist/{turn-lifecycle-BfodfmiY.js → turn-lifecycle-BUP7ZOVa.js} +1 -1
  45. package/dist/{turn-session-routing-BAh_qsBJ.js → turn-session-routing-BcWM3PLm.js} +1 -1
  46. package/dist/{validation-LzIilOb6.js → validation-DCd69-cP.js} +1 -1
  47. package/dist/{version-CDM8Rq6E.js → version-DBc4Qt_P.js} +1 -1
  48. package/dist/version.js +1 -1
  49. package/dist/{viewer-Rnim7alE.js → viewer-C-9nFKYr.js} +3 -3
  50. package/dist/{web-input-Dc1VwcT4.js → web-input-Cv42P3ni.js} +26 -26
  51. package/dist/{work-BAn43SsN.js → work-6UmVQq1V.js} +9 -9
  52. package/dist/{worker-mBXq4_zg.js → worker-DAoBZuZn.js} +5 -5
  53. package/package.json +5 -5
@@ -1,6 +1,6 @@
1
- import { N as getDeploymentServiceVersion, P as getDeploymentTelemetryAttributes } from "./logging-D3aYP0aG.js";
1
+ import { N as getDeploymentServiceVersion, P as getDeploymentTelemetryAttributes } from "./logging-tPQeUe2i.js";
2
2
  import { _ as vercelAIIntegration, a as getClient, b as withStreamedSpan, c as init, o as getGlobalScope } from "./sentry-CgWZM_kV.js";
3
- import { n as getCurrentConversationPrivacy } from "./conversation-privacy-1ERtieuM.js";
3
+ import { n as getCurrentConversationPrivacy } from "./conversation-privacy-CpSYOWnP.js";
4
4
  import { t as consumePrivateTraceResultMarker } from "./private-trace-result-BLvBjy_e.js";
5
5
  //#region src/chat/sentry-payload-filter.ts
6
6
  const PAYLOAD_ATTRIBUTE_KEYS = /* @__PURE__ */ new Set([
@@ -1,4 +1,4 @@
1
- import { i as getChatConfig } from "./config-BDAfLTI9.js";
1
+ import { i as getChatConfig } from "./config-DdBiDanf.js";
2
2
  import { AsyncLocalStorage } from "node:async_hooks";
3
3
  import { z } from "zod";
4
4
  import { createHash, createHmac, timingSafeEqual } from "node:crypto";
@@ -1,5 +1,5 @@
1
1
  import { d as setTag, f as setUser, h as startSpan, i as getActiveSpan, l as logger, n as captureMessage, p as spanToJSON, s as getTraceData, t as captureException, y as withScope } from "./sentry-CgWZM_kV.js";
2
- import { t as JUNIOR_VERSION } from "./version-CDM8Rq6E.js";
2
+ import { t as JUNIOR_VERSION } from "./version-DBc4Qt_P.js";
3
3
  import path from "node:path";
4
4
  import { styleText } from "node:util";
5
5
  import { ConfigError, configureSync, getConfig, getLogger } from "@logtape/logtape";
@@ -1,7 +1,7 @@
1
1
  import { t as __exportAll } from "./rolldown-runtime-B4FMCO8f.js";
2
- import { Ht as toolInvocationDestination, Q as getActiveAgentInvocationForConversation, Vt as actorFromRun, Y as createAgentInvocationForMessage, Z as findChildAgentConversationId, _t as AgentMessageTargetError, vt as PARENT_AGENT_TARGET } from "./agent-runner-Caiof09f.js";
3
- import { n as enqueueAgentMessageToParent } from "./result-Df5nEDX2.js";
4
- import { r as enqueueAgentInvocation } from "./work-BAn43SsN.js";
2
+ import { Ht as toolInvocationDestination, Q as getActiveAgentInvocationForConversation, Vt as actorFromRun, Y as createAgentInvocationForMessage, Z as findChildAgentConversationId, _t as AgentMessageTargetError, vt as PARENT_AGENT_TARGET } from "./agent-runner-C6_cd61V.js";
3
+ import { n as enqueueAgentMessageToParent } from "./result-j9nS0se-.js";
4
+ import { r as enqueueAgentInvocation } from "./work-6UmVQq1V.js";
5
5
  //#region src/chat/agent-invocations/message.ts
6
6
  var message_exports = /* @__PURE__ */ __exportAll({ bindMessageAgent: () => bindMessageAgent });
7
7
  /**
package/dist/nitro.js CHANGED
@@ -1,8 +1,8 @@
1
- import { A as JUNIOR_RETENTION_ROUTE, D as JUNIOR_HEARTBEAT_ROUTE, E as JUNIOR_HEARTBEAT_CRON_SCHEDULE, O as JUNIOR_PLUGIN_TASK_CALLBACK_ROUTE, T as JUNIOR_CONVERSATION_WORK_CALLBACK_ROUTE, j as JUNIOR_WORKSPACE_SNAPSHOT_JOB_CALLBACK_ROUTE, k as JUNIOR_RETENTION_CRON_SCHEDULE } from "./logging-D3aYP0aG.js";
1
+ import { A as JUNIOR_RETENTION_ROUTE, D as JUNIOR_HEARTBEAT_ROUTE, E as JUNIOR_HEARTBEAT_CRON_SCHEDULE, O as JUNIOR_PLUGIN_TASK_CALLBACK_ROUTE, T as JUNIOR_CONVERSATION_WORK_CALLBACK_ROUTE, j as JUNIOR_WORKSPACE_SNAPSHOT_JOB_CALLBACK_ROUTE, k as JUNIOR_RETENTION_CRON_SCHEDULE } from "./logging-tPQeUe2i.js";
2
2
  import { d as resolvePackageDir, t as discoverInstalledPluginPackageContent, u as isValidPackageName } from "./package-discovery-BVvSnQBB.js";
3
- import { o as resolveConversationWorkQueueTopic, t as WORKSPACE_SNAPSHOT_JOB_QUEUE_TOPIC } from "./job-queue-BaCL36FY.js";
3
+ import { o as resolveConversationWorkQueueTopic, t as WORKSPACE_SNAPSHOT_JOB_QUEUE_TOPIC } from "./job-queue-BbGg3gvu.js";
4
4
  import { a as pluginRuntimeRegistrationsFromPluginSet, r as pluginCatalogConfigFromPluginSet } from "./plugins-egKWjgue.js";
5
- import { t as PLUGIN_TASK_QUEUE_TOPIC } from "./task-queue-VvIKqlQ4.js";
5
+ import { t as PLUGIN_TASK_QUEUE_TOPIC } from "./task-queue-ZMk9bLRT.js";
6
6
  import { n as loadPluginSetFromModule, r as resolvePluginModule } from "./plugin-module-CVvEUSMH.js";
7
7
  import path from "node:path";
8
8
  import { cpSync, existsSync, mkdirSync, readdirSync, statSync } from "node:fs";
@@ -1,5 +1,5 @@
1
- import { Lt as createUserTokenStore } from "./agent-runner-Caiof09f.js";
2
- import { a as GET, n as syncLocalOAuthCredential, r as GET$1 } from "./credential-sync-BZuqqIHk.js";
1
+ import { Lt as createUserTokenStore } from "./agent-runner-C6_cd61V.js";
2
+ import { a as GET, n as syncLocalOAuthCredential, r as GET$1 } from "./credential-sync-DKWNdcgm.js";
3
3
  import { createServer } from "node:http";
4
4
  //#region src/chat/local/oauth-callback-server.ts
5
5
  const LOCAL_OAUTH_TIMEOUT_MS = 6e5;
@@ -1,5 +1,5 @@
1
- import { v as isProviderRetryError } from "./client-Clj7onnT.js";
2
- import { cn as estimateTextTokens, q as abandonTurnRecord } from "./tasks-dJooqiip.js";
1
+ import { v as isProviderRetryError } from "./client-BVrAp-pq.js";
2
+ import { cn as estimateTextTokens, q as abandonTurnRecord } from "./tasks-CODtRzvX.js";
3
3
  import { r as isExperimentalFeatureEnabled } from "./experimental-Qn9rKLgx.js";
4
4
  import { z } from "zod";
5
5
  //#region src/chat/state/turn-id.ts
@@ -1,7 +1,7 @@
1
- import { S as toOptionalTrimmed } from "./client-Clj7onnT.js";
2
- import { v as setSpanAttributes, y as setSpanStatus } from "./logging-D3aYP0aG.js";
3
- import { i as getChatConfig } from "./config-BDAfLTI9.js";
4
- import { n as pluginCatalogRuntime } from "./catalog-runtime-hKmI-iZa.js";
1
+ import { S as toOptionalTrimmed } from "./client-BVrAp-pq.js";
2
+ import { v as setSpanAttributes, y as setSpanStatus } from "./logging-tPQeUe2i.js";
3
+ import { i as getChatConfig } from "./config-DdBiDanf.js";
4
+ import { n as pluginCatalogRuntime } from "./catalog-runtime-DF5OWqCc.js";
5
5
  import { createHash } from "node:crypto";
6
6
  import { createMemoryState } from "@chat-adapter/state-memory";
7
7
  import { createRedisState } from "@chat-adapter/state-redis";
@@ -1,4 +1,4 @@
1
- import { f as logInfo, p as logWarn, v as setSpanAttributes } from "./logging-D3aYP0aG.js";
1
+ import { f as logInfo, p as logWarn, v as setSpanAttributes } from "./logging-tPQeUe2i.js";
2
2
  import { o as parseActorUserId } from "./actor-BTtLaeWy.js";
3
3
  import { n as normalizePluginPackageNames, o as pluginRoots, t as discoverInstalledPluginPackageContent } from "./package-discovery-BVvSnQBB.js";
4
4
  import path from "node:path";
@@ -1,5 +1,5 @@
1
- import { v as setSpanAttributes, w as withSpan } from "./logging-D3aYP0aG.js";
2
- import { N as SANDBOX_WORKSPACE_ROOT, k as sleep, r as isStale, t as create, u as isSandboxUnavailableError, v as getVercelSandboxCredentials, w as getStateAdapter, x as runNonInteractiveCommand } from "./profile-DnkX3e2S.js";
1
+ import { v as setSpanAttributes, w as withSpan } from "./logging-tPQeUe2i.js";
2
+ import { N as SANDBOX_WORKSPACE_ROOT, k as sleep, r as isStale, t as create, u as isSandboxUnavailableError, v as getVercelSandboxCredentials, w as getStateAdapter, x as runNonInteractiveCommand } from "./profile-Bb1zCVGP.js";
3
3
  import { z } from "zod";
4
4
  import { FileSystem, Sandbox } from "@vercel/sandbox";
5
5
  //#region src/chat/sandbox/resources.ts
@@ -1,12 +1,12 @@
1
1
  import { t as __exportAll } from "./rolldown-runtime-B4FMCO8f.js";
2
- import { $ as getAgentInvocation, X as createAgentInvocationFromLatest, ct as isTerminalAgentInvocation, et as getAgentInvocationIdForEvents, ft as markAgentInvocationParentMailboxAppended, it as getAgentInvocationResultMessageId, nt as getAgentInvocationIdForResult, st as getLatestAgentInvocationForConversation, tt as getAgentInvocationIdForMessage } from "./agent-runner-Caiof09f.js";
2
+ import { $ as getAgentInvocation, X as createAgentInvocationFromLatest, ct as isTerminalAgentInvocation, et as getAgentInvocationIdForEvents, ft as markAgentInvocationParentMailboxAppended, it as getAgentInvocationResultMessageId, nt as getAgentInvocationIdForResult, st as getLatestAgentInvocationForConversation, tt as getAgentInvocationIdForMessage } from "./agent-runner-C6_cd61V.js";
3
3
  import { t as createActor } from "./actor-BTtLaeWy.js";
4
- import { d as credentialContextForActor } from "./registry-CmKmKHpp.js";
5
- import { X as getTurnRecord, Z as listTurnSummaries } from "./tasks-dJooqiip.js";
6
- import { a as EVENT_WAIT_MS, c as timerWatchCredentialSubject, s as isEventMailboxMetadata } from "./session-stop-BEBfE97J.js";
4
+ import { d as credentialContextForActor } from "./registry-CsNavQ_Z.js";
5
+ import { X as getTurnRecord, Z as listTurnSummaries } from "./tasks-CODtRzvX.js";
6
+ import { a as EVENT_WAIT_MS, c as timerWatchCredentialSubject, s as isEventMailboxMetadata } from "./session-stop-q-6GNHx6.js";
7
7
  import { a as EVENT_SYSTEM_ACTOR, i as EVENT_MESSAGE_AUTHOR, o as isEventConversationMessage } from "./prompt-C04mP1hu.js";
8
- import { r as appendAndEnqueueInboundMessage } from "./store-BashBewg.js";
9
- import { r as enqueueAgentInvocation } from "./work-BAn43SsN.js";
8
+ import { r as appendAndEnqueueInboundMessage } from "./store-D2It0ozF.js";
9
+ import { r as enqueueAgentInvocation } from "./work-6UmVQq1V.js";
10
10
  import { z } from "zod";
11
11
  import { createEventSource, createLocalSource, createWebSource } from "@sentry/junior-plugin-api";
12
12
  //#region src/chat/task-execution/mailbox-input.ts
@@ -1,14 +1,14 @@
1
- import { C as withLogContext, b as setTags, d as logException } from "./logging-D3aYP0aG.js";
2
- import { c as getConversationEventStore, u as getConversationStore } from "./viewer-Rnim7alE.js";
3
- import { d as credentialContextForActor } from "./registry-CmKmKHpp.js";
4
- import { $ as persistWithRetry, Ct as commitAcceptedReply, Ft as recordAuthorizationCompleted, K as saveTurnCheckpoint, Ot as loadProjection, Qt as buildConversationContext, Ut as hydrateConversationMessages, Wt as persistConversationMessages, an as recordDeliveredAssistantMessage, in as normalizeConversationText, rn as markConversationMessage, sn as upsertConversationMessage } from "./tasks-dJooqiip.js";
1
+ import { C as withLogContext, b as setTags, d as logException } from "./logging-tPQeUe2i.js";
2
+ import { c as getConversationEventStore, u as getConversationStore } from "./viewer-C-9nFKYr.js";
3
+ import { d as credentialContextForActor } from "./registry-CsNavQ_Z.js";
4
+ import { $ as persistWithRetry, Ct as commitAcceptedReply, Ft as recordAuthorizationCompleted, K as saveTurnCheckpoint, Ot as loadProjection, Qt as buildConversationContext, Ut as hydrateConversationMessages, Wt as persistConversationMessages, an as recordDeliveredAssistantMessage, in as normalizeConversationText, rn as markConversationMessage, sn as upsertConversationMessage } from "./tasks-CODtRzvX.js";
5
5
  import { K as messageCardText } from "./conversation-T18Xlkx9.js";
6
6
  import { f as markTurnFailed, p as startActiveTurn, t as authorizationId } from "./oauth-authorization-BA4Dt6a7.js";
7
- import { n as getAssistantReplyText } from "./assistant-reply-BddmM66R.js";
8
- import { n as scheduleSessionCompletedPluginTasks, t as processPluginTask } from "./task-runner-D2CpD6GN.js";
9
- import { t as ConversationTurnLifecycleService } from "./turn-lifecycle-BfodfmiY.js";
10
- import { n as getPersistedSandboxState, o as persistThreadStateById, r as getPersistedThreadState, s as coerceThreadConversationState } from "./thread-state-CsMC-ob0.js";
11
- import { d as loadPendingMessageCards, i as completeAuthPauseTurn, l as buildDeliveredTurnStatePatch, t as finalizeFailedTurnReplyWithEvent } from "./turn-failure-response-zB364t7_.js";
7
+ import { n as getAssistantReplyText } from "./assistant-reply-yn5G-YEG.js";
8
+ import { n as scheduleSessionCompletedPluginTasks, t as processPluginTask } from "./task-runner-cIGU5VwJ.js";
9
+ import { t as ConversationTurnLifecycleService } from "./turn-lifecycle-BUP7ZOVa.js";
10
+ import { n as getPersistedSandboxState, o as persistThreadStateById, r as getPersistedThreadState, s as coerceThreadConversationState } from "./thread-state-BPkwVmvK.js";
11
+ import { d as loadPendingMessageCards, i as completeAuthPauseTurn, l as buildDeliveredTurnStatePatch, t as finalizeFailedTurnReplyWithEvent } from "./turn-failure-response-ChmMeKar.js";
12
12
  import { randomUUID } from "node:crypto";
13
13
  import { createLocalSource, localDestinationSchema } from "@sentry/junior-plugin-api";
14
14
  //#region src/chat/local/runner.ts
@@ -1,4 +1,4 @@
1
- import { Mt as sandboxEgressSignalsResponseSchema } from "./agent-runner-Caiof09f.js";
1
+ import { Mt as sandboxEgressSignalsResponseSchema } from "./agent-runner-C6_cd61V.js";
2
2
  //#region src/chat/local/sandbox-egress-signals.ts
3
3
  const SANDBOX_EGRESS_SIGNALS_PATH = "/api/internal/sandbox-egress/signals";
4
4
  const LOCAL_DEV_SERVER_TIMEOUT_MS = 1e3;
@@ -1,16 +1,16 @@
1
1
  import { t as __exportAll } from "./rolldown-runtime-B4FMCO8f.js";
2
- import { d as logException, f as logInfo, p as logWarn } from "./logging-D3aYP0aG.js";
3
- import { n as botConfig } from "./config-BDAfLTI9.js";
4
- import { f as getSqlExecutor, u as getConversationStore } from "./viewer-Rnim7alE.js";
2
+ import { d as logException, f as logInfo, p as logWarn } from "./logging-tPQeUe2i.js";
3
+ import { n as botConfig } from "./config-DdBiDanf.js";
4
+ import { f as getSqlExecutor, u as getConversationStore } from "./viewer-C-9nFKYr.js";
5
5
  import { s as juniorConversations } from "./agent-invocations-BY60iNw-.js";
6
- import "./executor-Dh4Ofsnx.js";
7
- import { p as credentialSubjectSchema } from "./registry-CmKmKHpp.js";
8
- import { St as ToolInputError, _t as normalizeToolNameFromResult, gt as isToolResultMessage, ht as isToolResultError, pt as isAssistantMessage, z as postSlackMessage } from "./tasks-dJooqiip.js";
9
- import { it as JUNIOR_THREAD_STATE_TTL_MS, rt as verifyTimerWatchCredentialSubject, u as getPlugins } from "./agent-hooks-CDVx26Uu.js";
10
- import { w as getStateAdapter } from "./profile-DnkX3e2S.js";
11
- import { r as sanitizeAssistantText } from "./assistant-reply-BddmM66R.js";
6
+ import "./executor-BroK9oKy.js";
7
+ import { p as credentialSubjectSchema } from "./registry-CsNavQ_Z.js";
8
+ import { St as ToolInputError, _t as normalizeToolNameFromResult, gt as isToolResultMessage, ht as isToolResultError, pt as isAssistantMessage, z as postSlackMessage } from "./tasks-CODtRzvX.js";
9
+ import { it as JUNIOR_THREAD_STATE_TTL_MS, rt as verifyTimerWatchCredentialSubject, u as getPlugins } from "./agent-hooks-DlSK8PQQ.js";
10
+ import { w as getStateAdapter } from "./profile-Bb1zCVGP.js";
11
+ import { r as sanitizeAssistantText } from "./assistant-reply-yn5G-YEG.js";
12
12
  import { r as EVENT_AUTHOR_ID } from "./prompt-C04mP1hu.js";
13
- import { r as appendAndEnqueueInboundMessage } from "./store-BashBewg.js";
13
+ import { r as appendAndEnqueueInboundMessage } from "./store-D2It0ozF.js";
14
14
  import { z } from "zod";
15
15
  import { eq, inArray } from "drizzle-orm";
16
16
  import { eventMatchSchema, normalizeEventIdentifier, objectTypeSchema } from "@sentry/junior-plugin-api";
@@ -1,7 +1,7 @@
1
1
  import { t as __exportAll } from "./rolldown-runtime-B4FMCO8f.js";
2
- import { p as logWarn } from "./logging-D3aYP0aG.js";
2
+ import { p as logWarn } from "./logging-tPQeUe2i.js";
3
3
  import { s as skillRoots } from "./package-discovery-BVvSnQBB.js";
4
- import { n as pluginCatalogRuntime } from "./catalog-runtime-hKmI-iZa.js";
4
+ import { n as pluginCatalogRuntime } from "./catalog-runtime-DF5OWqCc.js";
5
5
  import path from "node:path";
6
6
  import { z } from "zod";
7
7
  import fs from "node:fs/promises";
@@ -1,6 +1,6 @@
1
1
  import { t as __exportAll } from "./rolldown-runtime-B4FMCO8f.js";
2
- import { Ht as toolInvocationDestination, Vt as actorFromRun } from "./agent-runner-Caiof09f.js";
3
- import { n as createAndEnqueueAgentInvocation } from "./work-BAn43SsN.js";
2
+ import { Ht as toolInvocationDestination, Vt as actorFromRun } from "./agent-runner-C6_cd61V.js";
3
+ import { n as createAndEnqueueAgentInvocation } from "./work-6UmVQq1V.js";
4
4
  //#region src/chat/agent-invocations/spawn.ts
5
5
  var spawn_exports = /* @__PURE__ */ __exportAll({ bindSpawnAgent: () => bindSpawnAgent });
6
6
  /** Bind a Run's Actor and credentials to new Agent invocations. */
@@ -1,10 +1,10 @@
1
- import { I as isRecord, L as toOptionalNumber, R as toOptionalString } from "./logging-D3aYP0aG.js";
2
- import { i as getChatConfig } from "./config-BDAfLTI9.js";
1
+ import { I as isRecord, L as toOptionalNumber, R as toOptionalString } from "./logging-tPQeUe2i.js";
2
+ import { i as getChatConfig } from "./config-DdBiDanf.js";
3
3
  import { s as parseStoredSlackActor } from "./actor-BTtLaeWy.js";
4
- import { F as sameDestination, N as parseDestination, u as getConversationStore } from "./viewer-Rnim7alE.js";
5
- import { it as JUNIOR_THREAD_STATE_TTL_MS } from "./agent-hooks-CDVx26Uu.js";
6
- import { C as getDefaultRedisStateAdapterFor, w as getStateAdapter } from "./profile-DnkX3e2S.js";
7
- import "./job-queue-BaCL36FY.js";
4
+ import { F as sameDestination, N as parseDestination, u as getConversationStore } from "./viewer-C-9nFKYr.js";
5
+ import { it as JUNIOR_THREAD_STATE_TTL_MS } from "./agent-hooks-DlSK8PQQ.js";
6
+ import { C as getDefaultRedisStateAdapterFor, w as getStateAdapter } from "./profile-Bb1zCVGP.js";
7
+ import "./job-queue-BbGg3gvu.js";
8
8
  import { z } from "zod";
9
9
  import { randomUUID } from "node:crypto";
10
10
  import { destinationSchema } from "@sentry/junior-plugin-api";
@@ -1,5 +1,5 @@
1
- import { p as logWarn } from "./logging-D3aYP0aG.js";
2
- import { c as QUEUE_SIGNATURE_MAX_AGE_MS, d as createVercelQueueClient, l as signQueueMessage, p as runWithTurnRequestDeadline, u as verifyQueueMessage } from "./job-queue-BaCL36FY.js";
1
+ import { p as logWarn } from "./logging-tPQeUe2i.js";
2
+ import { c as QUEUE_SIGNATURE_MAX_AGE_MS, d as createVercelQueueClient, l as signQueueMessage, p as runWithTurnRequestDeadline, u as verifyQueueMessage } from "./job-queue-BbGg3gvu.js";
3
3
  import { z } from "zod";
4
4
  import { createHash } from "node:crypto";
5
5
  import { handleCallback, registerDevConsumer } from "@vercel/queue";
@@ -115,7 +115,7 @@ function pluginTaskCallback() {
115
115
  maxDeliveries: PLUGIN_TASK_MAX_DELIVERIES,
116
116
  onRejected: logPluginTaskQueueMessageRejected,
117
117
  run: async (message) => {
118
- const { processPluginTask } = await import("./task-runner-D2CpD6GN.js").then((n) => n.r);
118
+ const { processPluginTask } = await import("./task-runner-cIGU5VwJ.js").then((n) => n.r);
119
119
  await processPluginTask(message);
120
120
  },
121
121
  topic: PLUGIN_TASK_QUEUE_TOPIC,
@@ -1,17 +1,17 @@
1
1
  import { t as __exportAll } from "./rolldown-runtime-B4FMCO8f.js";
2
- import { h as runBestEffort, p as logWarn } from "./logging-D3aYP0aG.js";
2
+ import { h as runBestEffort, p as logWarn } from "./logging-tPQeUe2i.js";
3
3
  import { g as parseSlackMessageTs } from "./actor-BTtLaeWy.js";
4
- import { C as agentTurnTotalTokens, S as agentTurnCostUsd, d as getDb, r as readActorIdentity, u as getConversationStore } from "./viewer-Rnim7alE.js";
4
+ import { C as agentTurnTotalTokens, S as agentTurnCostUsd, d as getDb, r as readActorIdentity, u as getConversationStore } from "./viewer-C-9nFKYr.js";
5
5
  import { s as juniorConversations } from "./agent-invocations-BY60iNw-.js";
6
- import { o as juniorAutomationRuns, s as juniorAutomations } from "./executor-Dh4Ofsnx.js";
6
+ import { o as juniorAutomationRuns, s as juniorAutomations } from "./executor-BroK9oKy.js";
7
7
  import { m as sameActorIdentity } from "./history-9pO1Zd4Y.js";
8
- import { p as credentialSubjectSchema } from "./registry-CmKmKHpp.js";
9
- import { A as formatSlackLink, L as openSlackDirectMessage, Ut as hydrateConversationMessages, X as getTurnRecord, Yt as fallbackShortTitle, _t as normalizeToolNameFromResult, ct as getPiMessageRole, ft as instructionTextForProjection, gt as isToolResultMessage, ht as isToolResultError, i as readScheduledAutomation, k as escapeSlackMrkdwnText, l as blockEventAutomation, m as getEventAutomation, yt as stripRuntimeTurnContext, z as postSlackMessage } from "./tasks-dJooqiip.js";
10
- import { St as createPluginConversationEvents, dt as createPluginModel, ft as createPluginLogger, it as JUNIOR_THREAD_STATE_TTL_MS, lt as createPluginState, p as coreTaskRegistrations, st as getDashboardTaskLink, u as getPlugins, ut as createPluginEmbedder } from "./agent-hooks-CDVx26Uu.js";
11
- import { w as getStateAdapter } from "./profile-DnkX3e2S.js";
12
- import { r as getPersistedThreadState, s as coerceThreadConversationState } from "./thread-state-CsMC-ob0.js";
13
- import { t as resolveConversationRouting } from "./turn-session-routing-BAh_qsBJ.js";
14
- import { i as pluginTaskParamsSchema, o as sendVercelPluginTask, r as pluginTaskId } from "./task-queue-VvIKqlQ4.js";
8
+ import { p as credentialSubjectSchema } from "./registry-CsNavQ_Z.js";
9
+ import { A as formatSlackLink, L as openSlackDirectMessage, Ut as hydrateConversationMessages, X as getTurnRecord, Yt as fallbackShortTitle, _t as normalizeToolNameFromResult, ct as getPiMessageRole, ft as instructionTextForProjection, gt as isToolResultMessage, ht as isToolResultError, i as readScheduledAutomation, k as escapeSlackMrkdwnText, l as blockEventAutomation, m as getEventAutomation, yt as stripRuntimeTurnContext, z as postSlackMessage } from "./tasks-CODtRzvX.js";
10
+ import { St as createPluginConversationEvents, dt as createPluginModel, ft as createPluginLogger, it as JUNIOR_THREAD_STATE_TTL_MS, lt as createPluginState, p as coreTaskRegistrations, st as getDashboardTaskLink, u as getPlugins, ut as createPluginEmbedder } from "./agent-hooks-DlSK8PQQ.js";
11
+ import { w as getStateAdapter } from "./profile-Bb1zCVGP.js";
12
+ import { r as getPersistedThreadState, s as coerceThreadConversationState } from "./thread-state-BPkwVmvK.js";
13
+ import { t as resolveConversationRouting } from "./turn-session-routing-BcWM3PLm.js";
14
+ import { i as pluginTaskParamsSchema, o as sendVercelPluginTask, r as pluginTaskId } from "./task-queue-ZMk9bLRT.js";
15
15
  import { z } from "zod";
16
16
  import { createHash } from "node:crypto";
17
17
  import { and, asc, count, desc, eq, gte, inArray, isNotNull, lte, max, sql } from "drizzle-orm";
@@ -1,15 +1,15 @@
1
- import { d as unwrapCurrentInstruction, f as escapeXml, i as completeText, o as resolveGatewayModel } from "./client-Clj7onnT.js";
2
- import { d as logException, o as getActiveTraceId, p as logWarn, s as getLogContextAttributes, t as buildTurnFailureResponse, v as setSpanAttributes } from "./logging-D3aYP0aG.js";
1
+ import { d as unwrapCurrentInstruction, f as escapeXml, i as completeText, o as resolveGatewayModel } from "./client-BVrAp-pq.js";
2
+ import { d as logException, o as getActiveTraceId, p as logWarn, s as getLogContextAttributes, t as buildTurnFailureResponse, v as setSpanAttributes } from "./logging-tPQeUe2i.js";
3
3
  import { n as captureMessage } from "./sentry-CgWZM_kV.js";
4
- import { n as botConfig, v as normalizeSlackEmojiName } from "./config-BDAfLTI9.js";
4
+ import { n as botConfig, v as normalizeSlackEmojiName } from "./config-DdBiDanf.js";
5
5
  import { c as toStoredSlackActor, f as parseSlackUserId, g as parseSlackMessageTs } from "./actor-BTtLaeWy.js";
6
- import { c as getConversationEventStore, f as getSqlExecutor, m as withConversationEventLock, p as createSqlConversationEventStore, u as getConversationStore, v as startLocationThread, x as addAgentTurnUsage, y as bindProviderConversation } from "./viewer-Rnim7alE.js";
7
- import { a as juniorAutomationVersions, o as juniorAutomationRuns, s as juniorAutomations } from "./executor-Dh4Ofsnx.js";
6
+ import { c as getConversationEventStore, f as getSqlExecutor, m as withConversationEventLock, p as createSqlConversationEventStore, u as getConversationStore, v as startLocationThread, x as addAgentTurnUsage, y as bindProviderConversation } from "./viewer-C-9nFKYr.js";
7
+ import { a as juniorAutomationVersions, o as juniorAutomationRuns, s as juniorAutomations } from "./executor-BroK9oKy.js";
8
8
  import { d as contextProvenance, f as instructionActors, n as agentHistoryItemSchema, p as instructionProvenanceFor } from "./history-9pO1Zd4Y.js";
9
- import { p as credentialSubjectSchema } from "./registry-CmKmKHpp.js";
10
- import { $t as authenticationUnlinkedEvent, Gt as normalizeSlackConversationId, Ht as getSlackClient, Qt as authenticationLinkedEvent, Rt as SlackActionError, Xt as JUNIOR_NATIVE_EVENT_NAMESPACE, Zt as agentsInstructionsUpdatedEvent, n as applyPluginFormatMarkdown, qt as withSlackRetries } from "./agent-hooks-CDVx26Uu.js";
9
+ import { p as credentialSubjectSchema } from "./registry-CsNavQ_Z.js";
10
+ import { $t as authenticationUnlinkedEvent, Gt as normalizeSlackConversationId, Ht as getSlackClient, Qt as authenticationLinkedEvent, Rt as SlackActionError, Xt as JUNIOR_NATIVE_EVENT_NAMESPACE, Zt as agentsInstructionsUpdatedEvent, n as applyPluginFormatMarkdown, qt as withSlackRetries } from "./agent-hooks-DlSK8PQQ.js";
11
11
  import { G as messageCardRef } from "./conversation-T18Xlkx9.js";
12
- import { D as fenceLock, O as withLock, T as MUTATION_LOCK_TTL_MS, k as sleep, w as getStateAdapter } from "./profile-DnkX3e2S.js";
12
+ import { D as fenceLock, O as withLock, T as MUTATION_LOCK_TTL_MS, k as sleep, w as getStateAdapter } from "./profile-Bb1zCVGP.js";
13
13
  import { A as eventAutomationSchema, E as scheduledAutomationSchema, S as automationVersionSchema } from "./automation-CHdlHVZP.js";
14
14
  import { isDeepStrictEqual } from "node:util";
15
15
  import { z } from "zod";
@@ -1,10 +1,10 @@
1
- import { I as isRecord, L as toOptionalNumber, R as toOptionalString } from "./logging-D3aYP0aG.js";
2
- import { d as getDb } from "./viewer-Rnim7alE.js";
1
+ import { I as isRecord, L as toOptionalNumber, R as toOptionalString } from "./logging-tPQeUe2i.js";
2
+ import { d as getDb } from "./viewer-C-9nFKYr.js";
3
3
  import { d as juniorDestinations } from "./agent-invocations-BY60iNw-.js";
4
- import { l as juniorLocationConfigurations } from "./executor-Dh4Ofsnx.js";
5
- import { Wt as persistConversationMessages } from "./tasks-dJooqiip.js";
6
- import { it as JUNIOR_THREAD_STATE_TTL_MS } from "./agent-hooks-CDVx26Uu.js";
7
- import { w as getStateAdapter } from "./profile-DnkX3e2S.js";
4
+ import { l as juniorLocationConfigurations } from "./executor-BroK9oKy.js";
5
+ import { Wt as persistConversationMessages } from "./tasks-CODtRzvX.js";
6
+ import { it as JUNIOR_THREAD_STATE_TTL_MS } from "./agent-hooks-DlSK8PQQ.js";
7
+ import { w as getStateAdapter } from "./profile-Bb1zCVGP.js";
8
8
  import { z } from "zod";
9
9
  import { randomUUID } from "node:crypto";
10
10
  import { and, eq, sql } from "drizzle-orm";
@@ -1,13 +1,13 @@
1
- import { _ as getProviderErrorUserMessage, g as getProviderErrorAttributes, h as findProviderError, p as ProviderError } from "./client-Clj7onnT.js";
2
- import { I as isRecord, t as buildTurnFailureResponse } from "./logging-D3aYP0aG.js";
1
+ import { _ as getProviderErrorUserMessage, g as getProviderErrorAttributes, h as findProviderError, p as ProviderError } from "./client-BVrAp-pq.js";
2
+ import { I as isRecord, t as buildTurnFailureResponse } from "./logging-tPQeUe2i.js";
3
3
  import { g as parseSlackMessageTs } from "./actor-BTtLaeWy.js";
4
- import { c as getConversationEventStore, d as getDb } from "./viewer-Rnim7alE.js";
5
- import { Ut as hydrateConversationMessages, rn as markConversationMessage } from "./tasks-dJooqiip.js";
6
- import { Nt as listConversationAnnotations } from "./agent-hooks-CDVx26Uu.js";
4
+ import { c as getConversationEventStore, d as getDb } from "./viewer-C-9nFKYr.js";
5
+ import { Ut as hydrateConversationMessages, rn as markConversationMessage } from "./tasks-CODtRzvX.js";
6
+ import { Nt as listConversationAnnotations } from "./agent-hooks-DlSK8PQQ.js";
7
7
  import { J as removedCardSchema, Y as resolveMessageCards, q as readMessageCardRefs } from "./conversation-T18Xlkx9.js";
8
- import { r as clearPendingAuth, u as buildDeterministicTurnId } from "./pending-auth-D2t1Moxf.js";
8
+ import { r as clearPendingAuth, u as buildDeterministicTurnId } from "./pending-auth-DT3MRVW8.js";
9
9
  import { d as markTurnCompleted, u as markTurnClosed } from "./oauth-authorization-BA4Dt6a7.js";
10
- import { o as persistThreadStateById, r as getPersistedThreadState, s as coerceThreadConversationState } from "./thread-state-CsMC-ob0.js";
10
+ import { o as persistThreadStateById, r as getPersistedThreadState, s as coerceThreadConversationState } from "./thread-state-BPkwVmvK.js";
11
11
  //#region src/chat/conversations/pending-cards.ts
12
12
  /** Select undelivered cards and load their latest saved facts. */
13
13
  async function loadPendingMessageCards(conversationId) {
@@ -1,4 +1,4 @@
1
- import { c as getConversationEventStore } from "./viewer-Rnim7alE.js";
1
+ import { c as getConversationEventStore } from "./viewer-C-9nFKYr.js";
2
2
  //#region src/chat/conversations/turn-lifecycle.ts
3
3
  /** Persist correlated turn lifecycle facts with retry-safe terminal exclusion. */
4
4
  var ConversationTurnLifecycleService = class {
@@ -34,7 +34,7 @@ function slackSourceForDestination(args) {
34
34
  * Reads parent Conversations when this Conversation has no Destination.
35
35
  */
36
36
  async function resolveConversationRouting(args) {
37
- const conversationStore = args.conversationStore ?? (await import("./viewer-Rnim7alE.js").then((n) => n.s)).getConversationStore();
37
+ const conversationStore = args.conversationStore ?? (await import("./viewer-C-9nFKYr.js").then((n) => n.s)).getConversationStore();
38
38
  const chain = await loadConversationChain(args.conversationId, conversationStore);
39
39
  let destination;
40
40
  let source;
@@ -1,5 +1,5 @@
1
1
  import { t as __exportAll } from "./rolldown-runtime-B4FMCO8f.js";
2
- import { n as pluginCatalogRuntime } from "./catalog-runtime-hKmI-iZa.js";
2
+ import { n as pluginCatalogRuntime } from "./catalog-runtime-DF5OWqCc.js";
3
3
  import { isDeepStrictEqual } from "node:util";
4
4
  //#region src/chat/plugins/validation.ts
5
5
  var validation_exports = /* @__PURE__ */ __exportAll({
@@ -1,5 +1,5 @@
1
1
  //#region package.json
2
- var version = "0.255.0";
2
+ var version = "0.256.0";
3
3
  //#endregion
4
4
  //#region src/version.ts
5
5
  /** Installed Junior package version, or `unknown` when package metadata is unavailable. */
package/dist/version.js CHANGED
@@ -1,2 +1,2 @@
1
- import { t as JUNIOR_VERSION } from "./version-CDM8Rq6E.js";
1
+ import { t as JUNIOR_VERSION } from "./version-DBc4Qt_P.js";
2
2
  export { JUNIOR_VERSION };
@@ -1,9 +1,9 @@
1
1
  import { t as __exportAll } from "./rolldown-runtime-B4FMCO8f.js";
2
- import { F as normalizeIdentityEmail } from "./logging-D3aYP0aG.js";
3
- import { i as getChatConfig } from "./config-BDAfLTI9.js";
2
+ import { F as normalizeIdentityEmail } from "./logging-tPQeUe2i.js";
3
+ import { i as getChatConfig } from "./config-DdBiDanf.js";
4
4
  import { d as parseSlackTeamId, o as parseActorUserId, u as parseSlackChannelReferenceId } from "./actor-BTtLaeWy.js";
5
5
  import { c as juniorIdentities, d as juniorDestinations, l as juniorUsers, o as conversationReadColumns, s as juniorConversations } from "./agent-invocations-BY60iNw-.js";
6
- import { _ as juniorConversationAnnotations, d as juniorConversationBindings, h as juniorConversationEvents, m as juniorConversationMetrics, p as CONVERSATION_METRICS, t as createJuniorSqlExecutor, u as juniorConversationParticipants } from "./executor-Dh4Ofsnx.js";
6
+ import { _ as juniorConversationAnnotations, d as juniorConversationBindings, h as juniorConversationEvents, m as juniorConversationMetrics, p as CONVERSATION_METRICS, t as createJuniorSqlExecutor, u as juniorConversationParticipants } from "./executor-BroK9oKy.js";
7
7
  import { c as newConversationEventSchema, h as usageSchema, l as encodeHistoryPayload, o as decodeStoredConversationEvent, r as conversationEventDataSchema, s as historyReplacementSchema } from "./history-9pO1Zd4Y.js";
8
8
  import { randomUUID } from "node:crypto";
9
9
  import { and, asc, desc, eq, gt, gte, inArray, isNull, lt, lte, ne, or, sql } from "drizzle-orm";
@@ -1,39 +1,39 @@
1
- import { A as resolveSlackChannelIdFromMessage, B as effectiveTaskOutcomes, Bt as RetryableDeliveryError, C as renderBlockText, D as storeAttachment, Gt as shouldEmitDevAgentTrace, Lt as createUserTokenStore, M as getConversationInfo, N as listThreadReplies, O as parseSlackThreadId, Rt as buildSteeringPiMessage, S as renderAttachmentText, Ut as AuthorizationFlowDisabledError, a as buildAuthPauseResponse, h as latestProgressStatus, j as resolveSlackChannelIdFromThreadId, k as readSlackRawMessageContext, m as PluginCredentialFailureError, n as executeAgentRun, r as createContextCompactor, t as createAgentRunner, z as eventAutomationTriggerAvailable, zt as withoutSavedSteeringMessages } from "./agent-runner-Caiof09f.js";
2
- import { f as escapeXml, i as completeText, r as completeObject, v as isProviderRetryError } from "./client-Clj7onnT.js";
3
- import { C as withLogContext, I as isRecord, L as toOptionalNumber, R as toOptionalString, _ as setSentryUser, b as setTags, d as logException, f as logInfo, n as createChatSdkLogger, o as getActiveTraceId, p as logWarn, t as buildTurnFailureResponse, u as logError, v as setSpanAttributes, w as withSpan } from "./logging-D3aYP0aG.js";
4
- import { c as getSlackClientSecret, i as getChatConfig, l as getSlackSigningSecret, n as botConfig, o as getSlackBotToken, s as getSlackClientId, v as normalizeSlackEmojiName } from "./config-BDAfLTI9.js";
1
+ import { A as resolveSlackChannelIdFromMessage, B as effectiveTaskOutcomes, Bt as RetryableDeliveryError, C as renderBlockText, D as storeAttachment, Gt as shouldEmitDevAgentTrace, Lt as createUserTokenStore, M as getConversationInfo, N as listThreadReplies, O as parseSlackThreadId, Rt as buildSteeringPiMessage, S as renderAttachmentText, Ut as AuthorizationFlowDisabledError, a as buildAuthPauseResponse, h as latestProgressStatus, j as resolveSlackChannelIdFromThreadId, k as readSlackRawMessageContext, m as PluginCredentialFailureError, n as executeAgentRun, r as createContextCompactor, t as createAgentRunner, z as eventAutomationTriggerAvailable, zt as withoutSavedSteeringMessages } from "./agent-runner-C6_cd61V.js";
2
+ import { f as escapeXml, i as completeText, r as completeObject, v as isProviderRetryError } from "./client-BVrAp-pq.js";
3
+ import { C as withLogContext, I as isRecord, L as toOptionalNumber, R as toOptionalString, _ as setSentryUser, b as setTags, d as logException, f as logInfo, n as createChatSdkLogger, o as getActiveTraceId, p as logWarn, t as buildTurnFailureResponse, u as logError, v as setSpanAttributes, w as withSpan } from "./logging-tPQeUe2i.js";
4
+ import { c as getSlackClientSecret, i as getChatConfig, l as getSlackSigningSecret, n as botConfig, o as getSlackBotToken, s as getSlackClientId, v as normalizeSlackEmojiName } from "./config-DdBiDanf.js";
5
5
  import { o as modelIdForProfile, r as defaultModelId } from "./model-profile-BwU8mqwD.js";
6
6
  import { a as isUserActor, g as parseSlackMessageTs, i as isActorUserId, l as parseSlackChannelId, n as createSlackActor, o as parseActorUserId, r as createSlackResumeActor, t as createActor } from "./actor-BTtLaeWy.js";
7
- import { M as createSlackDestination, P as requireSlackDestination, c as getConversationEventStore, d as getDb, f as getSqlExecutor, u as getConversationStore } from "./viewer-Rnim7alE.js";
7
+ import { M as createSlackDestination, P as requireSlackDestination, c as getConversationEventStore, d as getDb, f as getSqlExecutor, u as getConversationStore } from "./viewer-C-9nFKYr.js";
8
8
  import { c as juniorIdentities, d as juniorDestinations, l as juniorUsers } from "./agent-invocations-BY60iNw-.js";
9
- import { o as juniorAutomationRuns, s as juniorAutomations } from "./executor-Dh4Ofsnx.js";
9
+ import { o as juniorAutomationRuns, s as juniorAutomations } from "./executor-BroK9oKy.js";
10
10
  import { p as instructionProvenanceFor } from "./history-9pO1Zd4Y.js";
11
- import { d as credentialContextForActor } from "./registry-CmKmKHpp.js";
12
- import { $ as persistWithRetry, $t as createConversationMemoryService, A as formatSlackLink, B as removeReactionFromMessage, C as listAutomationVersions, Ct as commitAcceptedReply, Et as loadConversationProjection, F as addReactionToMessage, Ft as recordAuthorizationCompleted, G as loadTurnCheckpoint, J as completeTurnRecord, K as saveTurnCheckpoint, Kt as persistConversationMessageSummaries, M as normalizeSlackStatusText, Ot as loadProjection, P as truncateStatusText, Q as recordTurnSummary, Qt as buildConversationContext, S as automationDefinition, T as sameDefinitionValue, Ut as hydrateConversationMessages, Wt as persistConversationMessages, X as getTurnRecord, Y as failTurnRecord, Yt as fallbackShortTitle, Z as listTurnSummaries, Zt as appendThreadContextMessages, _ as parseEventAutomationRow, an as recordDeliveredAssistantMessage, bt as trimTrailingAssistantMessages, c as withScheduledAutomationLock, en as estimateConversationContextTokens, f as deleteEventAutomation, h as listDeletedEventAutomationsCreatedBy, i as readScheduledAutomation, in as normalizeConversationText, it as buildTurnErrorResponse, j as normalizeSlackReplyMarkdown, k as escapeSlackMrkdwnText, nn as isHumanConversationMessage, o as saveScheduledAutomationInLock, on as turnHasReply, q as abandonTurnRecord, qt as resolveConversationTitle, r as parseScheduledAutomationRow, rn as markConversationMessage, sn as upsertConversationMessage, tn as getConversationMessageSlackTs, wt as commitMessages, z as postSlackMessage, zt as recordSubscribedReplyRoute } from "./tasks-dJooqiip.js";
13
- import { Et as getSlackFileId, Gt as normalizeSlackConversationId, Ht as getSlackClient, Kt as runWithSlackInstallationToken, Lt as lookupSlackUser, Ot as readAttachmentVisionSummary, Rt as SlackActionError, Tt as buildSentryConversationUrl, V as cancelSubscriptions, Vt as getHeaderString, Wt as isDmChannel, at as getDashboardConversationLink, it as JUNIOR_THREAD_STATE_TTL_MS, kt as recordSlackAttachment, o as getPluginSlackConversationLink, ot as getDashboardObjectIconLink, rt as verifyTimerWatchCredentialSubject, zt as downloadPrivateSlackFile } from "./agent-hooks-CDVx26Uu.js";
11
+ import { d as credentialContextForActor } from "./registry-CsNavQ_Z.js";
12
+ import { $ as persistWithRetry, $t as createConversationMemoryService, A as formatSlackLink, B as removeReactionFromMessage, C as listAutomationVersions, Ct as commitAcceptedReply, Et as loadConversationProjection, F as addReactionToMessage, Ft as recordAuthorizationCompleted, G as loadTurnCheckpoint, J as completeTurnRecord, K as saveTurnCheckpoint, Kt as persistConversationMessageSummaries, M as normalizeSlackStatusText, Ot as loadProjection, P as truncateStatusText, Q as recordTurnSummary, Qt as buildConversationContext, S as automationDefinition, T as sameDefinitionValue, Ut as hydrateConversationMessages, Wt as persistConversationMessages, X as getTurnRecord, Y as failTurnRecord, Yt as fallbackShortTitle, Z as listTurnSummaries, Zt as appendThreadContextMessages, _ as parseEventAutomationRow, an as recordDeliveredAssistantMessage, bt as trimTrailingAssistantMessages, c as withScheduledAutomationLock, en as estimateConversationContextTokens, f as deleteEventAutomation, h as listDeletedEventAutomationsCreatedBy, i as readScheduledAutomation, in as normalizeConversationText, it as buildTurnErrorResponse, j as normalizeSlackReplyMarkdown, k as escapeSlackMrkdwnText, nn as isHumanConversationMessage, o as saveScheduledAutomationInLock, on as turnHasReply, q as abandonTurnRecord, qt as resolveConversationTitle, r as parseScheduledAutomationRow, rn as markConversationMessage, sn as upsertConversationMessage, tn as getConversationMessageSlackTs, wt as commitMessages, z as postSlackMessage, zt as recordSubscribedReplyRoute } from "./tasks-CODtRzvX.js";
13
+ import { Et as getSlackFileId, Gt as normalizeSlackConversationId, Ht as getSlackClient, Kt as runWithSlackInstallationToken, Lt as lookupSlackUser, Ot as readAttachmentVisionSummary, Rt as SlackActionError, Tt as buildSentryConversationUrl, V as cancelSubscriptions, Vt as getHeaderString, Wt as isDmChannel, at as getDashboardConversationLink, it as JUNIOR_THREAD_STATE_TTL_MS, kt as recordSlackAttachment, o as getPluginSlackConversationLink, ot as getDashboardObjectIconLink, rt as verifyTimerWatchCredentialSubject, zt as downloadPrivateSlackFile } from "./agent-hooks-DlSK8PQQ.js";
14
14
  import { F as readMessageAttachments, R as isVisionImageMediaType } from "./conversation-T18Xlkx9.js";
15
- import { E as acquireActiveLock, O as withLock, T as MUTATION_LOCK_TTL_MS, w as getStateAdapter } from "./profile-DnkX3e2S.js";
16
- import { a as wasPendingAuthStopped, c as getThreadStopDecision, l as buildDeterministicAssistantMessageId, o as decideSubscribedThreadReply, r as clearPendingAuth, s as getSubscribedReplyPreflightDecision, u as buildDeterministicTurnId } from "./pending-auth-D2t1Moxf.js";
15
+ import { E as acquireActiveLock, O as withLock, T as MUTATION_LOCK_TTL_MS, w as getStateAdapter } from "./profile-Bb1zCVGP.js";
16
+ import { a as wasPendingAuthStopped, c as getThreadStopDecision, l as buildDeterministicAssistantMessageId, o as decideSubscribedThreadReply, r as clearPendingAuth, s as getSubscribedReplyPreflightDecision, u as buildDeterministicTurnId } from "./pending-auth-DT3MRVW8.js";
17
17
  import { a as TurnInputDeferredError, c as isTurnInputCommitLostError, d as markTurnCompleted, f as markTurnFailed, i as TurnInputCommitLostError, l as isTurnInputDeferredError, n as ConversationTurnBoundaryError, o as getConversationTurnBoundaryError, p as startActiveTurn, r as CooperativeTurnYieldError, s as isCooperativeTurnYieldError, u as markTurnClosed } from "./oauth-authorization-BA4Dt6a7.js";
18
- import { n as getAssistantReplyText } from "./assistant-reply-BddmM66R.js";
19
- import { A as recordFinishedTurnForAutomatedLimit, F as finishedRunReply, P as deliversFinalText, R as runDispatchOutcome, c as timerWatchCredentialSubject, i as skipInputBeforeConversationStop, k as maybePostAutomatedTurnLimitNotice, l as getEventCatalog, s as isEventMailboxMetadata, v as automationEventCatalog } from "./session-stop-BEBfE97J.js";
18
+ import { n as getAssistantReplyText } from "./assistant-reply-yn5G-YEG.js";
19
+ import { A as recordFinishedTurnForAutomatedLimit, F as finishedRunReply, P as deliversFinalText, R as runDispatchOutcome, c as timerWatchCredentialSubject, i as skipInputBeforeConversationStop, k as maybePostAutomatedTurnLimitNotice, l as getEventCatalog, s as isEventMailboxMetadata, v as automationEventCatalog } from "./session-stop-q-6GNHx6.js";
20
20
  import { a as EVENT_SYSTEM_ACTOR, o as isEventConversationMessage } from "./prompt-C04mP1hu.js";
21
- import { a as getVercelConversationWorkQueue, f as getTurnRequestDeadline } from "./job-queue-BaCL36FY.js";
22
- import { E as stopConversationWork, g as getConversationWorkState, h as getConversation, m as ensureConversationWake, n as appendAndEnqueueExclusiveInboundMessage, r as appendAndEnqueueInboundMessage, w as requestConversationWork } from "./store-BashBewg.js";
21
+ import { a as getVercelConversationWorkQueue, f as getTurnRequestDeadline } from "./job-queue-BbGg3gvu.js";
22
+ import { E as stopConversationWork, g as getConversationWorkState, h as getConversation, m as ensureConversationWake, n as appendAndEnqueueExclusiveInboundMessage, r as appendAndEnqueueInboundMessage, w as requestConversationWork } from "./store-D2It0ozF.js";
23
23
  import { l as automationListQuerySchema } from "./automation-CHdlHVZP.js";
24
24
  import { r as isExperimentalFeatureEnabled } from "./experimental-Qn9rKLgx.js";
25
25
  import { c as sumUtcHoursIntoSixHours, m as healthReportSchema, t as webMessageId } from "./web-message-id-xPI_EFSC.js";
26
- import { A as readAutomationRuns, C as readAutomationExecutionByConversationId, D as readAutomationExecutionStatusHours, E as readAutomationExecutionStatusDays, O as readAutomationExecutionSummaries, T as readAutomationExecutionHours, _ as markDispatchCompleted, a as confirmDispatchMailboxAppend, c as getDispatchIdForConversation, d as getDispatchTurnId, g as markDispatchBlocked, h as markDispatchAwaitingResume, i as claimDispatchMailboxAppend, k as readAutomationExecutions, l as getDispatchInputMessageId, n as scheduleSessionCompletedPluginTasks, p as isTerminalDispatchStatus, s as getDispatchConversationId, t as processPluginTask, u as getDispatchRecord, v as markDispatchFailed, w as readAutomationExecutionDays, x as emptyAutomationRunWindows, y as markDispatchRunning } from "./task-runner-D2CpD6GN.js";
27
- import { a as withAgentInvocationResultActors, c as resolveMailboxTurnWork, f as joinMailboxText, i as startAgentInvocationsForChildInput, l as sourceFromTurnInput, o as getAuthPausedConversationTurnId, s as getEventBatchDelayMs, t as enqueueAgentInvocationResult, u as turnInputFactsFromConversationMessage } from "./result-Df5nEDX2.js";
28
- import { n as getTurnLifecycle, t as ConversationTurnLifecycleService } from "./turn-lifecycle-BfodfmiY.js";
29
- import { i as resolveAgentInvocationId, o as AgentRunError, s as executeTurn, t as createAgentInvocationWorker } from "./work-BAn43SsN.js";
30
- import { a as persistThreadState, c as configValueSchema, i as persistThreadRuntimeState, n as getPersistedSandboxState, o as persistThreadStateById, r as getPersistedThreadState, s as coerceThreadConversationState, t as getLocationConfigurationService } from "./thread-state-CsMC-ob0.js";
31
- import { c as deleteWebAuthorization, d as getPausedTurnRequest, m as getTurnAuthorization, p as wakePausedTurn, s as createWebAuthorization, u as createPausedTurns } from "./connections-BC0RTejT.js";
32
- import { n as resolveTurnSessionRouting } from "./turn-session-routing-BAh_qsBJ.js";
33
- import { t as bindMessageAgent } from "./message-B9xqD2BP.js";
34
- import { t as bindSpawnAgent } from "./spawn-OgTwBUj0.js";
35
- import { a as persistAuthPauseTurnState, c as getTurnUserSlackMessageTs, d as loadPendingMessageCards, i as completeAuthPauseTurn, l as buildDeliveredTurnStatePatch, n as getAgentTurnDiagnosticsAttributes, o as getTurnUserMessage, r as requireTurnFailureEventId, s as getTurnUserReplyAttachmentContext, t as finalizeFailedTurnReplyWithEvent, u as getInterruptionMarker } from "./turn-failure-response-zB364t7_.js";
36
- import { r as storeInputImages } from "./images-C-WOnTc_.js";
26
+ import { A as readAutomationRuns, C as readAutomationExecutionByConversationId, D as readAutomationExecutionStatusHours, E as readAutomationExecutionStatusDays, O as readAutomationExecutionSummaries, T as readAutomationExecutionHours, _ as markDispatchCompleted, a as confirmDispatchMailboxAppend, c as getDispatchIdForConversation, d as getDispatchTurnId, g as markDispatchBlocked, h as markDispatchAwaitingResume, i as claimDispatchMailboxAppend, k as readAutomationExecutions, l as getDispatchInputMessageId, n as scheduleSessionCompletedPluginTasks, p as isTerminalDispatchStatus, s as getDispatchConversationId, t as processPluginTask, u as getDispatchRecord, v as markDispatchFailed, w as readAutomationExecutionDays, x as emptyAutomationRunWindows, y as markDispatchRunning } from "./task-runner-cIGU5VwJ.js";
27
+ import { a as withAgentInvocationResultActors, c as resolveMailboxTurnWork, f as joinMailboxText, i as startAgentInvocationsForChildInput, l as sourceFromTurnInput, o as getAuthPausedConversationTurnId, s as getEventBatchDelayMs, t as enqueueAgentInvocationResult, u as turnInputFactsFromConversationMessage } from "./result-j9nS0se-.js";
28
+ import { n as getTurnLifecycle, t as ConversationTurnLifecycleService } from "./turn-lifecycle-BUP7ZOVa.js";
29
+ import { i as resolveAgentInvocationId, o as AgentRunError, s as executeTurn, t as createAgentInvocationWorker } from "./work-6UmVQq1V.js";
30
+ import { a as persistThreadState, c as configValueSchema, i as persistThreadRuntimeState, n as getPersistedSandboxState, o as persistThreadStateById, r as getPersistedThreadState, s as coerceThreadConversationState, t as getLocationConfigurationService } from "./thread-state-BPkwVmvK.js";
31
+ import { c as deleteWebAuthorization, d as getPausedTurnRequest, m as getTurnAuthorization, p as wakePausedTurn, s as createWebAuthorization, u as createPausedTurns } from "./connections-CG04HdpC.js";
32
+ import { n as resolveTurnSessionRouting } from "./turn-session-routing-BcWM3PLm.js";
33
+ import { t as bindMessageAgent } from "./message-DdPGRYQP.js";
34
+ import { t as bindSpawnAgent } from "./spawn-Do5mX3d_.js";
35
+ import { a as persistAuthPauseTurnState, c as getTurnUserSlackMessageTs, d as loadPendingMessageCards, i as completeAuthPauseTurn, l as buildDeliveredTurnStatePatch, n as getAgentTurnDiagnosticsAttributes, o as getTurnUserMessage, r as requireTurnFailureEventId, s as getTurnUserReplyAttachmentContext, t as finalizeFailedTurnReplyWithEvent, u as getInterruptionMarker } from "./turn-failure-response-ChmMeKar.js";
36
+ import { r as storeInputImages } from "./images-D0VZ5nv0.js";
37
37
  import { z } from "zod";
38
38
  import { createHash } from "node:crypto";
39
39
  import { and, asc, count, desc, eq, exists, inArray, ne, or, sql } from "drizzle-orm";
@@ -1,15 +1,15 @@
1
1
  import { t as __exportAll } from "./rolldown-runtime-B4FMCO8f.js";
2
- import { $ as getAgentInvocation, G as recordSubagentStarted, H as stopChildAgentsOf, J as createAgentInvocation, Q as getActiveAgentInvocationForConversation, Rt as buildSteeringPiMessage, Ut as AuthorizationFlowDisabledError, W as recordSubagentEnded, Wt as readBlockedReport, at as getAgentInvocationTurnId, ct as isTerminalAgentInvocation, dt as markAgentInvocationMailboxAppended, gt as reportReplacedAgentInvocation, ht as markAgentInvocationSteered, m as PluginCredentialFailureError, mt as markAgentInvocationRunning, pt as markAgentInvocationPaused, q as completeAgentInvocation, rt as getAgentInvocationMessageId, st as getLatestAgentInvocationForConversation, zt as withoutSavedSteeringMessages } from "./agent-runner-Caiof09f.js";
3
- import { n as botConfig } from "./config-BDAfLTI9.js";
4
- import { c as getConversationEventStore, u as getConversationStore } from "./viewer-Rnim7alE.js";
2
+ import { $ as getAgentInvocation, G as recordSubagentStarted, H as stopChildAgentsOf, J as createAgentInvocation, Q as getActiveAgentInvocationForConversation, Rt as buildSteeringPiMessage, Ut as AuthorizationFlowDisabledError, W as recordSubagentEnded, Wt as readBlockedReport, at as getAgentInvocationTurnId, ct as isTerminalAgentInvocation, dt as markAgentInvocationMailboxAppended, gt as reportReplacedAgentInvocation, ht as markAgentInvocationSteered, m as PluginCredentialFailureError, mt as markAgentInvocationRunning, pt as markAgentInvocationPaused, q as completeAgentInvocation, rt as getAgentInvocationMessageId, st as getLatestAgentInvocationForConversation, zt as withoutSavedSteeringMessages } from "./agent-runner-C6_cd61V.js";
3
+ import { n as botConfig } from "./config-DdBiDanf.js";
4
+ import { c as getConversationEventStore, u as getConversationStore } from "./viewer-C-9nFKYr.js";
5
5
  import { m as sameActorIdentity, u as agentInstructionProvenance } from "./history-9pO1Zd4Y.js";
6
- import { K as saveTurnCheckpoint, X as getTurnRecord, Y as failTurnRecord, jt as openConversationProjection, lt as getTerminalAssistantMessages, ot as isTurnExecutionLimitExceededError, q as abandonTurnRecord } from "./tasks-dJooqiip.js";
6
+ import { K as saveTurnCheckpoint, X as getTurnRecord, Y as failTurnRecord, jt as openConversationProjection, lt as getTerminalAssistantMessages, ot as isTurnExecutionLimitExceededError, q as abandonTurnRecord } from "./tasks-CODtRzvX.js";
7
7
  import { c as isTurnInputCommitLostError, i as TurnInputCommitLostError, o as getConversationTurnBoundaryError } from "./oauth-authorization-BA4Dt6a7.js";
8
- import { n as getAssistantReplyText } from "./assistant-reply-BddmM66R.js";
9
- import { A as recordFinishedTurnForAutomatedLimit, j as resetAutomatedTurnLimit, k as maybePostAutomatedTurnLimitNotice } from "./session-stop-BEBfE97J.js";
10
- import { r as appendAndEnqueueInboundMessage } from "./store-BashBewg.js";
11
- import { t as ConversationTurnLifecycleService } from "./turn-lifecycle-BfodfmiY.js";
12
- import { n as getPersistedSandboxState, o as persistThreadStateById, r as getPersistedThreadState } from "./thread-state-CsMC-ob0.js";
8
+ import { n as getAssistantReplyText } from "./assistant-reply-yn5G-YEG.js";
9
+ import { A as recordFinishedTurnForAutomatedLimit, j as resetAutomatedTurnLimit, k as maybePostAutomatedTurnLimitNotice } from "./session-stop-q-6GNHx6.js";
10
+ import { r as appendAndEnqueueInboundMessage } from "./store-D2It0ozF.js";
11
+ import { t as ConversationTurnLifecycleService } from "./turn-lifecycle-BUP7ZOVa.js";
12
+ import { n as getPersistedSandboxState, o as persistThreadStateById, r as getPersistedThreadState } from "./thread-state-BPkwVmvK.js";
13
13
  import { isDeepStrictEqual } from "node:util";
14
14
  import { z } from "zod";
15
15
  //#region src/chat/runtime/turn-execution.ts
@@ -1,9 +1,9 @@
1
1
  import { t as __exportAll } from "./rolldown-runtime-B4FMCO8f.js";
2
- import { v as isProviderRetryError } from "./client-Clj7onnT.js";
3
- import { C as withLogContext, d as logException, f as logInfo, p as logWarn } from "./logging-D3aYP0aG.js";
4
- import { i as getChatConfig } from "./config-BDAfLTI9.js";
5
- import { f as getTurnRequestDeadline, m as ConversationQueueMessageRejectedError } from "./job-queue-BaCL36FY.js";
6
- import { C as requestAnotherSlice, M as isInvalidConversationRecordError, T as startConversationWork, b as recordConversationRetry, d as countPendingConversationMessages, f as deadLetterAttempt, g as getConversationWorkState, i as beginConversationResume, j as isFinalAttempt, k as hasConversationStop, l as completeConversationStop, m as ensureConversationWake, o as checkInConversationWork, p as drainConversationMailbox, s as clearConsumedConversationWake, t as ackMessages, u as completeConversationWork, x as releaseConversationWork, y as recordAttemptFailure } from "./store-BashBewg.js";
2
+ import { v as isProviderRetryError } from "./client-BVrAp-pq.js";
3
+ import { C as withLogContext, d as logException, f as logInfo, p as logWarn } from "./logging-tPQeUe2i.js";
4
+ import { i as getChatConfig } from "./config-DdBiDanf.js";
5
+ import { f as getTurnRequestDeadline, m as ConversationQueueMessageRejectedError } from "./job-queue-BbGg3gvu.js";
6
+ import { C as requestAnotherSlice, M as isInvalidConversationRecordError, T as startConversationWork, b as recordConversationRetry, d as countPendingConversationMessages, f as deadLetterAttempt, g as getConversationWorkState, i as beginConversationResume, j as isFinalAttempt, k as hasConversationStop, l as completeConversationStop, m as ensureConversationWake, o as checkInConversationWork, p as drainConversationMailbox, s as clearConsumedConversationWake, t as ackMessages, u as completeConversationWork, x as releaseConversationWork, y as recordAttemptFailure } from "./store-D2It0ozF.js";
7
7
  //#region src/chat/task-execution/worker.ts
8
8
  var worker_exports = /* @__PURE__ */ __exportAll({
9
9
  CONVERSATION_WORK_DEFER_DELAY_MS: () => CONVERSATION_WORK_DEFER_DELAY_MS,
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@sentry/junior",
3
- "version": "0.255.0",
3
+ "version": "0.256.0",
4
4
  "private": false,
5
5
  "publishConfig": {
6
6
  "access": "public"
@@ -88,7 +88,7 @@
88
88
  "sharp": "^0.35.3",
89
89
  "yaml": "^2.9.0",
90
90
  "zod": "^4.5.4",
91
- "@sentry/junior-plugin-api": "0.255.0"
91
+ "@sentry/junior-plugin-api": "0.256.0"
92
92
  },
93
93
  "devDependencies": {
94
94
  "@emnapi/core": "^1.10.0",
@@ -107,9 +107,9 @@
107
107
  "typescript": "^6.0.3",
108
108
  "vercel": "^54.4.0",
109
109
  "vitest": "^4.1.7",
110
- "@sentry/junior-memory": "0.255.0",
111
- "@sentry/junior-testing": "0.0.0",
112
- "@sentry/junior-github": "0.255.0"
110
+ "@sentry/junior-github": "0.256.0",
111
+ "@sentry/junior-memory": "0.256.0",
112
+ "@sentry/junior-testing": "0.0.0"
113
113
  },
114
114
  "scripts": {
115
115
  "build": "tsdown",