@sentry/junior 0.136.0 → 0.137.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 (58) hide show
  1. package/dist/{agent-hooks-TQSI2FKN.js → agent-hooks-MZOKEP3J.js} +9 -9
  2. package/dist/api/conversations/projection.d.ts +1 -0
  3. package/dist/api/conversations/stats.d.ts +1 -0
  4. package/dist/api/schema/conversation.d.ts +2 -0
  5. package/dist/api/schema.js +1 -1
  6. package/dist/api.js +185 -47
  7. package/dist/app.d.ts +1 -1
  8. package/dist/app.js +293 -193
  9. package/dist/{catalog-runtime-VXL5EO2X.js → catalog-runtime-MD66YLFV.js} +5 -5
  10. package/dist/chat/configuration/defaults.d.ts +1 -1
  11. package/dist/chat/conversations/store.d.ts +2 -1
  12. package/dist/chat/pi/client.d.ts +1 -8
  13. package/dist/chat/pi/gateway-auth.d.ts +16 -0
  14. package/dist/chat/sandbox/docker.d.ts +17 -0
  15. package/dist/chat/services/agent-continue.d.ts +2 -0
  16. package/dist/chat/services/subscribed-reply-router-policy.d.ts +12 -0
  17. package/dist/chat/services/turn-session-routing.d.ts +17 -0
  18. package/dist/chat/slack/message.d.ts +6 -1
  19. package/dist/chat/slack/source-link.d.ts +8 -2
  20. package/dist/chat/slack/team-domain.d.ts +4 -0
  21. package/dist/chat/source.d.ts +5 -5
  22. package/dist/{chunk-IUSO5QUB.js → chunk-36EG34YI.js} +1 -1
  23. package/dist/{chunk-QCX3TRIM.js → chunk-3Q342EJJ.js} +2 -2
  24. package/dist/{chunk-5I3MXBNV.js → chunk-5G34IEK2.js} +1 -1
  25. package/dist/{chunk-ZIYDJIWQ.js → chunk-5PNJMOY5.js} +1 -1
  26. package/dist/{chunk-6ABWAONM.js → chunk-6QW2RRQT.js} +5 -5
  27. package/dist/{chunk-4VDQGQHY.js → chunk-BZAMASJP.js} +1 -1
  28. package/dist/{chunk-XRC4TXJ4.js → chunk-DQXAAVTR.js} +43 -20
  29. package/dist/{chunk-HEGTNY2S.js → chunk-EWDSB24B.js} +7 -7
  30. package/dist/{chunk-TRZSM67C.js → chunk-HCIVH3JS.js} +1 -0
  31. package/dist/{chunk-CGZ6O74P.js → chunk-K2NCQJKH.js} +3 -3
  32. package/dist/{chunk-3NLQQ7DC.js → chunk-KJ4HGRHN.js} +24 -26
  33. package/dist/{chunk-3TOCJOYJ.js → chunk-POBSY47Q.js} +6 -4
  34. package/dist/{chunk-BTBTQEXF.js → chunk-RB4NJKEX.js} +1 -1
  35. package/dist/{chunk-UIAZI7UJ.js → chunk-SYCX4DOK.js} +34 -17
  36. package/dist/{chunk-BECYUPSQ.js → chunk-T6Z5S6PQ.js} +1 -1
  37. package/dist/{chunk-QE4DN7JQ.js → chunk-UG6ZYPBI.js} +42 -19
  38. package/dist/{chunk-CTKCGKWB.js → chunk-UOXATPSI.js} +203 -77
  39. package/dist/{chunk-2E5D3Z3U.js → chunk-UZQ4VY3M.js} +1 -1
  40. package/dist/{chunk-76Y5A57F.js → chunk-WPPXIAFB.js} +5 -5
  41. package/dist/{chunk-DO37VD6O.js → chunk-XZ7NPXAB.js} +2 -1
  42. package/dist/{chunk-KRUSDASP.js → chunk-YNFERGKP.js} +1 -1
  43. package/dist/{chunk-3UUDZPO5.js → chunk-YRPC6MJY.js} +1 -1
  44. package/dist/{chunk-4ULSYOL6.js → chunk-ZFS67WIR.js} +4 -7
  45. package/dist/cli/chat.js +24 -24
  46. package/dist/cli/check.js +7 -7
  47. package/dist/cli/plugins.js +12 -12
  48. package/dist/cli/snapshot-create.js +9 -9
  49. package/dist/cli/upgrade.js +7 -7
  50. package/dist/{db-NN6T27OO.js → db-66E7VDNC.js} +7 -7
  51. package/dist/instrumentation.js +4 -4
  52. package/dist/nitro.js +2 -2
  53. package/dist/{oauth-callback-server-VJQ27ITN.js → oauth-callback-server-7QPD4Q7P.js} +17 -17
  54. package/dist/{runner-ZHI3GQII.js → runner-L2BKJKOD.js} +11 -11
  55. package/dist/{skills-YT5ZSNAW.js → skills-HOQ2NSPW.js} +6 -6
  56. package/dist/{validation-EKUNT5IY.js → validation-ENHI7S2C.js} +6 -6
  57. package/dist/version.js +1 -1
  58. package/package.json +6 -5
@@ -2,18 +2,18 @@ import {
2
2
  SANDBOX_WORKSPACE_ROOT,
3
3
  getStateAdapter,
4
4
  sleep
5
- } from "./chunk-5I3MXBNV.js";
5
+ } from "./chunk-5G34IEK2.js";
6
6
  import {
7
7
  toOptionalTrimmed
8
- } from "./chunk-QE4DN7JQ.js";
8
+ } from "./chunk-UG6ZYPBI.js";
9
9
  import {
10
10
  pluginCatalogRuntime
11
- } from "./chunk-IUSO5QUB.js";
11
+ } from "./chunk-36EG34YI.js";
12
12
  import {
13
13
  setSpanAttributes,
14
14
  setSpanStatus,
15
15
  withSpan
16
- } from "./chunk-BECYUPSQ.js";
16
+ } from "./chunk-T6Z5S6PQ.js";
17
17
 
18
18
  // src/chat/sandbox/resources.ts
19
19
  var configuredResources;
@@ -50,12 +50,181 @@ function getSandboxResources() {
50
50
  // src/chat/sandbox/snapshot/profile.ts
51
51
  import { createHash } from "crypto";
52
52
 
53
+ // src/chat/sandbox/noninteractive-command.ts
54
+ var NON_INTERACTIVE_ENV = {
55
+ CI: "1",
56
+ TERM: "dumb",
57
+ NO_COLOR: "1",
58
+ PAGER: "cat",
59
+ GIT_PAGER: "cat",
60
+ GH_PROMPT_DISABLED: "1",
61
+ GH_NO_UPDATE_NOTIFIER: "1",
62
+ GH_NO_EXTENSION_UPDATE_NOTIFIER: "1",
63
+ GH_SPINNER_DISABLED: "1",
64
+ GIT_TERMINAL_PROMPT: "0",
65
+ GCM_INTERACTIVE: "never",
66
+ DEBIAN_FRONTEND: "noninteractive",
67
+ // Git credential isolation: prevent git from sending its own auth so the
68
+ // sandbox egress proxy's header transforms are the sole credential source.
69
+ GIT_ASKPASS: "/bin/true",
70
+ GIT_CONFIG_NOSYSTEM: "1",
71
+ GIT_CONFIG_COUNT: "2",
72
+ GIT_CONFIG_KEY_0: "credential.helper",
73
+ GIT_CONFIG_VALUE_0: "",
74
+ GIT_CONFIG_KEY_1: "http.emptyAuth",
75
+ GIT_CONFIG_VALUE_1: "true"
76
+ };
77
+ function shellQuote(value) {
78
+ return `'${value.replace(/'/g, "'\\''")}'`;
79
+ }
80
+ function buildEnvExports(options) {
81
+ const lines = [];
82
+ if (options.pathPrefix) {
83
+ lines.push(`export PATH="${options.pathPrefix}"`);
84
+ }
85
+ for (const [key, value] of Object.entries(NON_INTERACTIVE_ENV)) {
86
+ lines.push(`export ${key}=${shellQuote(value)}`);
87
+ }
88
+ for (const [key, value] of Object.entries(options.env ?? {})) {
89
+ lines.push(`export ${key}=${shellQuote(value)}`);
90
+ }
91
+ return lines;
92
+ }
93
+ function buildCommandScript(input) {
94
+ return [shellQuote(input.cmd), ...(input.args ?? []).map(shellQuote)].join(
95
+ " "
96
+ );
97
+ }
98
+ function buildNonInteractiveShellScript(script, options = {}) {
99
+ return [...buildEnvExports(options), "exec </dev/null", script].join(" && ");
100
+ }
101
+ function buildNonInteractiveCommand(input) {
102
+ return {
103
+ cmd: "bash",
104
+ args: [
105
+ input.login ? "-lc" : "-c",
106
+ buildNonInteractiveShellScript(buildCommandScript(input), {
107
+ env: input.env,
108
+ pathPrefix: input.pathPrefix
109
+ })
110
+ ]
111
+ };
112
+ }
113
+ async function runNonInteractiveCommand(sandbox, input) {
114
+ const command = {
115
+ ...buildNonInteractiveCommand(input),
116
+ ...input.cwd ? { cwd: input.cwd } : {},
117
+ ...input.signal ? { signal: input.signal } : {},
118
+ ...input.sudo !== void 0 ? { sudo: input.sudo } : {}
119
+ };
120
+ return await sandbox.runCommand(command);
121
+ }
122
+
123
+ // src/chat/sandbox/docker.ts
124
+ var DOCKER_DAEMON_JSON = `{
125
+ "storage-driver": "overlay2",
126
+ "live-restore": false
127
+ }
128
+ `;
129
+ var DOCKER_ENSURE_SCRIPT = `#!/bin/sh
130
+ set -eu
131
+
132
+ if [ "$(id -u)" -ne 0 ]; then
133
+ exec sudo -n "$0" "$@"
134
+ fi
135
+
136
+ SOCK=/var/run/docker.sock
137
+ PIDFILE=/var/run/docker.pid
138
+ LOG=/var/log/junior-dockerd.log
139
+
140
+ is_ready() {
141
+ [ -S "$SOCK" ] && /usr/bin/docker info >/dev/null 2>&1
142
+ }
143
+
144
+ if is_ready; then
145
+ chmod 666 "$SOCK" 2>/dev/null || true
146
+ exit 0
147
+ fi
148
+
149
+ mkdir -p /etc/docker /var/lib/docker /var/run /var/log
150
+ if [ ! -f /etc/docker/daemon.json ]; then
151
+ cat > /etc/docker/daemon.json <<'EOF'
152
+ {
153
+ "storage-driver": "overlay2",
154
+ "live-restore": false
155
+ }
156
+ EOF
157
+ fi
158
+
159
+ if [ -f "$PIDFILE" ]; then
160
+ oldpid="$(cat "$PIDFILE" 2>/dev/null || true)"
161
+ if [ -n "\${oldpid:-}" ] && ! kill -0 "$oldpid" 2>/dev/null; then
162
+ rm -f "$PIDFILE"
163
+ fi
164
+ fi
165
+
166
+ if [ ! -f "$PIDFILE" ] || ! kill -0 "$(cat "$PIDFILE" 2>/dev/null)" 2>/dev/null; then
167
+ # dockerd must outlive this helper; nohup + background is intentional.
168
+ nohup dockerd --host="unix://$SOCK" --pidfile="$PIDFILE" >"$LOG" 2>&1 &
169
+ fi
170
+
171
+ i=0
172
+ while [ "$i" -lt 50 ]; do
173
+ if is_ready; then
174
+ chmod 666 "$SOCK" 2>/dev/null || true
175
+ exit 0
176
+ fi
177
+ i=$((i + 1))
178
+ sleep 0.1
179
+ done
180
+
181
+ echo "junior-ensure-docker: dockerd failed to become ready" >&2
182
+ if [ -f "$LOG" ]; then
183
+ tail -n 50 "$LOG" >&2 || true
184
+ fi
185
+ exit 1
186
+ `;
187
+ var DOCKER_CLI_WRAPPER_SCRIPT = `#!/bin/sh
188
+ set -eu
189
+ if command -v junior-ensure-docker >/dev/null 2>&1; then
190
+ junior-ensure-docker
191
+ fi
192
+ exec /usr/bin/docker "$@"
193
+ `;
194
+ var DOCKER_COMPOSE_CLI_WRAPPER_SCRIPT = `#!/bin/sh
195
+ set -eu
196
+ if command -v junior-ensure-docker >/dev/null 2>&1; then
197
+ junior-ensure-docker
198
+ fi
199
+ exec /usr/local/libexec/junior-docker-compose "$@"
200
+ `;
201
+ async function ensureDockerDaemon(sandbox, signal) {
202
+ await runNonInteractiveCommand(sandbox, {
203
+ cmd: "sh",
204
+ args: [
205
+ "-c",
206
+ "command -v junior-ensure-docker >/dev/null 2>&1 && junior-ensure-docker || true"
207
+ ],
208
+ signal
209
+ });
210
+ }
211
+
53
212
  // src/chat/sandbox/runtime-dependencies.ts
54
213
  var GLOBAL_RUNTIME_DEPENDENCIES = [
55
214
  { type: "system", package: "docker" },
56
215
  { type: "system", package: "spal-release" },
57
216
  { type: "system", package: "ripgrep" }
58
217
  ];
218
+ function writeFileCommand(path, contents, mode = "0644") {
219
+ const payload = Buffer.from(contents, "utf8").toString("base64");
220
+ return [
221
+ `printf '%s' '${payload}' | base64 -d > ${path}`,
222
+ `chmod ${mode} ${path}`
223
+ ].join("\n");
224
+ }
225
+ function writeExecutableCommand(path, contents) {
226
+ return writeFileCommand(path, contents, "0755");
227
+ }
59
228
  var GLOBAL_RUNTIME_POSTINSTALL = [
60
229
  {
61
230
  cmd: "sh",
@@ -72,9 +241,35 @@ var GLOBAL_RUNTIME_POSTINSTALL = [
72
241
  `trap 'rm -f "$tmp"' EXIT`,
73
242
  'curl --fail --location --silent --show-error "https://github.com/docker/compose/releases/download/v2.39.4/docker-compose-linux-${asset}" --output "$tmp"',
74
243
  'echo "${sha256} ${tmp}" | sha256sum --check --status',
75
- 'install -D -m 0755 "$tmp" /usr/local/bin/docker-compose',
76
- "mkdir -p /usr/local/lib/docker/cli-plugins",
77
- "ln -sf /usr/local/bin/docker-compose /usr/local/lib/docker/cli-plugins/docker-compose"
244
+ // Keep the real Compose binary off PATH; the wrapper below starts dockerd.
245
+ 'install -D -m 0755 "$tmp" /usr/local/libexec/junior-docker-compose',
246
+ "mkdir -p /usr/local/lib/docker/cli-plugins /usr/local/libexec /etc/docker /usr/local/bin",
247
+ `mkdir -p ${SANDBOX_WORKSPACE_ROOT}/.junior/bin`,
248
+ writeFileCommand("/etc/docker/daemon.json", DOCKER_DAEMON_JSON),
249
+ writeExecutableCommand(
250
+ "/usr/local/bin/junior-ensure-docker",
251
+ DOCKER_ENSURE_SCRIPT
252
+ ),
253
+ // docker compose plugin delegates to the real Compose binary.
254
+ "ln -sfn /usr/local/libexec/junior-docker-compose /usr/local/lib/docker/cli-plugins/docker-compose",
255
+ // PATH wrappers auto-start dockerd for both CLI entrypoints.
256
+ writeExecutableCommand(
257
+ "/usr/local/bin/docker-compose",
258
+ DOCKER_COMPOSE_CLI_WRAPPER_SCRIPT
259
+ ),
260
+ writeExecutableCommand(
261
+ `${SANDBOX_WORKSPACE_ROOT}/.junior/bin/docker`,
262
+ DOCKER_CLI_WRAPPER_SCRIPT
263
+ ),
264
+ writeExecutableCommand(
265
+ `${SANDBOX_WORKSPACE_ROOT}/.junior/bin/docker-compose`,
266
+ DOCKER_COMPOSE_CLI_WRAPPER_SCRIPT
267
+ ),
268
+ // Prefer the wrapper over /usr/bin/docker for non-login shells too.
269
+ writeExecutableCommand(
270
+ "/usr/local/bin/docker",
271
+ DOCKER_CLI_WRAPPER_SCRIPT
272
+ )
78
273
  ].join("\n")
79
274
  ],
80
275
  sudo: true
@@ -176,76 +371,6 @@ function getVercelSandboxCredentials() {
176
371
  return void 0;
177
372
  }
178
373
 
179
- // src/chat/sandbox/noninteractive-command.ts
180
- var NON_INTERACTIVE_ENV = {
181
- CI: "1",
182
- TERM: "dumb",
183
- NO_COLOR: "1",
184
- PAGER: "cat",
185
- GIT_PAGER: "cat",
186
- GH_PROMPT_DISABLED: "1",
187
- GH_NO_UPDATE_NOTIFIER: "1",
188
- GH_NO_EXTENSION_UPDATE_NOTIFIER: "1",
189
- GH_SPINNER_DISABLED: "1",
190
- GIT_TERMINAL_PROMPT: "0",
191
- GCM_INTERACTIVE: "never",
192
- DEBIAN_FRONTEND: "noninteractive",
193
- // Git credential isolation: prevent git from sending its own auth so the
194
- // sandbox egress proxy's header transforms are the sole credential source.
195
- GIT_ASKPASS: "/bin/true",
196
- GIT_CONFIG_NOSYSTEM: "1",
197
- GIT_CONFIG_COUNT: "2",
198
- GIT_CONFIG_KEY_0: "credential.helper",
199
- GIT_CONFIG_VALUE_0: "",
200
- GIT_CONFIG_KEY_1: "http.emptyAuth",
201
- GIT_CONFIG_VALUE_1: "true"
202
- };
203
- function shellQuote(value) {
204
- return `'${value.replace(/'/g, "'\\''")}'`;
205
- }
206
- function buildEnvExports(options) {
207
- const lines = [];
208
- if (options.pathPrefix) {
209
- lines.push(`export PATH="${options.pathPrefix}"`);
210
- }
211
- for (const [key, value] of Object.entries(NON_INTERACTIVE_ENV)) {
212
- lines.push(`export ${key}=${shellQuote(value)}`);
213
- }
214
- for (const [key, value] of Object.entries(options.env ?? {})) {
215
- lines.push(`export ${key}=${shellQuote(value)}`);
216
- }
217
- return lines;
218
- }
219
- function buildCommandScript(input) {
220
- return [shellQuote(input.cmd), ...(input.args ?? []).map(shellQuote)].join(
221
- " "
222
- );
223
- }
224
- function buildNonInteractiveShellScript(script, options = {}) {
225
- return [...buildEnvExports(options), "exec </dev/null", script].join(" && ");
226
- }
227
- function buildNonInteractiveCommand(input) {
228
- return {
229
- cmd: "bash",
230
- args: [
231
- input.login ? "-lc" : "-c",
232
- buildNonInteractiveShellScript(buildCommandScript(input), {
233
- env: input.env,
234
- pathPrefix: input.pathPrefix
235
- })
236
- ]
237
- };
238
- }
239
- async function runNonInteractiveCommand(sandbox, input) {
240
- const command = {
241
- ...buildNonInteractiveCommand(input),
242
- ...input.cwd ? { cwd: input.cwd } : {},
243
- ...input.signal ? { signal: input.signal } : {},
244
- ...input.sudo !== void 0 ? { sudo: input.sudo } : {}
245
- };
246
- return await sandbox.runCommand(command);
247
- }
248
-
249
374
  // src/chat/sandbox/snapshot/span.ts
250
375
  async function trace(name, op, attributes, callback) {
251
376
  return await withSpan(name, op, {}, callback, attributes);
@@ -1076,6 +1201,7 @@ export {
1076
1201
  wrapSandboxSetupError,
1077
1202
  throwSandboxOperationError,
1078
1203
  getVercelSandboxCredentials,
1204
+ ensureDockerDaemon,
1079
1205
  getSandboxResourceConfig,
1080
1206
  setSandboxResourceConfig,
1081
1207
  getSandboxResources,
@@ -1,6 +1,6 @@
1
1
  import {
2
2
  pluginCatalogRuntime
3
- } from "./chunk-IUSO5QUB.js";
3
+ } from "./chunk-36EG34YI.js";
4
4
 
5
5
  // src/chat/plugins/validation.ts
6
6
  import { isDeepStrictEqual } from "util";
@@ -1,25 +1,25 @@
1
1
  import {
2
2
  getConversationEventStore,
3
3
  getDb
4
- } from "./chunk-4ULSYOL6.js";
4
+ } from "./chunk-ZFS67WIR.js";
5
5
  import {
6
6
  juniorConversationAnnotations,
7
7
  juniorConversationEvents,
8
8
  juniorIdentities,
9
9
  juniorUsers
10
- } from "./chunk-BTBTQEXF.js";
10
+ } from "./chunk-RB4NJKEX.js";
11
11
  import {
12
12
  SANDBOX_WORKSPACE_ROOT,
13
13
  getStateAdapter,
14
14
  sleep
15
- } from "./chunk-5I3MXBNV.js";
15
+ } from "./chunk-5G34IEK2.js";
16
16
  import {
17
17
  botConfig,
18
18
  completeObject,
19
19
  embedTexts,
20
20
  getSlackBotToken,
21
21
  standardModelId
22
- } from "./chunk-QE4DN7JQ.js";
22
+ } from "./chunk-UG6ZYPBI.js";
23
23
  import {
24
24
  isActorUserId,
25
25
  parseActorUserId
@@ -37,7 +37,7 @@ import {
37
37
  setSpanAttributes,
38
38
  setSpanStatus,
39
39
  withSpan
40
- } from "./chunk-BECYUPSQ.js";
40
+ } from "./chunk-T6Z5S6PQ.js";
41
41
 
42
42
  // src/chat/plugins/agent-hooks.ts
43
43
  import {
@@ -1,7 +1,7 @@
1
1
  // package.json
2
2
  var package_default = {
3
3
  name: "@sentry/junior",
4
- version: "0.136.0",
4
+ version: "0.137.0",
5
5
  private: false,
6
6
  publishConfig: {
7
7
  access: "public"
@@ -81,6 +81,7 @@ var package_default = {
81
81
  "@sinclair/typebox": "^0.34.49",
82
82
  "@slack/web-api": "^7.16.0",
83
83
  "@vercel/functions": "^3.6.0",
84
+ "@vercel/oidc": "^3.4.1",
84
85
  "@vercel/queue": "^0.2.0",
85
86
  "@vercel/sandbox": "2.8.0",
86
87
  ai: "^6.0.190",
@@ -1,6 +1,6 @@
1
1
  import {
2
2
  logWarn
3
- } from "./chunk-BECYUPSQ.js";
3
+ } from "./chunk-T6Z5S6PQ.js";
4
4
 
5
5
  // src/chat/conversation-privacy.ts
6
6
  import { AsyncLocalStorage } from "async_hooks";
@@ -5,7 +5,7 @@ import {
5
5
  } from "./chunk-F3B2YJ76.js";
6
6
  import {
7
7
  toOptionalString
8
- } from "./chunk-BECYUPSQ.js";
8
+ } from "./chunk-T6Z5S6PQ.js";
9
9
 
10
10
  // src/chat/slack/context.ts
11
11
  import { z } from "zod";
@@ -5,12 +5,12 @@ import {
5
5
  juniorConversations,
6
6
  juniorIdentities,
7
7
  juniorUsers
8
- } from "./chunk-BTBTQEXF.js";
8
+ } from "./chunk-RB4NJKEX.js";
9
9
  import {
10
10
  TURN_REASONING_LEVELS,
11
11
  getChatConfig,
12
12
  modelProfileSchema
13
- } from "./chunk-QE4DN7JQ.js";
13
+ } from "./chunk-UG6ZYPBI.js";
14
14
  import {
15
15
  juniorDestinations
16
16
  } from "./chunk-VFUK3X5B.js";
@@ -20,7 +20,7 @@ import {
20
20
  } from "./chunk-F3B2YJ76.js";
21
21
  import {
22
22
  normalizeIdentityEmail
23
- } from "./chunk-BECYUPSQ.js";
23
+ } from "./chunk-T6Z5S6PQ.js";
24
24
 
25
25
  // src/chat/conversations/sql/store.ts
26
26
  import { randomUUID as randomUUID2 } from "crypto";
@@ -182,15 +182,12 @@ function normalizeSessionSource(value) {
182
182
  };
183
183
  }
184
184
  const threadTs = value.threadTs?.trim();
185
- if (!threadTs) {
186
- return void 0;
187
- }
188
185
  return {
189
186
  platform: "slack",
190
187
  visibility: value.visibility,
191
188
  teamId: value.teamId,
192
189
  channelId: value.channelId,
193
- threadTs
190
+ ...threadTs ? { threadTs } : {}
194
191
  };
195
192
  }
196
193
  function parseSessionSource(value) {
package/dist/cli/chat.js CHANGED
@@ -1,39 +1,39 @@
1
1
  import {
2
2
  createAgentRunner,
3
3
  executeAgentRun
4
- } from "../chunk-3NLQQ7DC.js";
4
+ } from "../chunk-KJ4HGRHN.js";
5
5
  import "../chunk-DIB4GX3G.js";
6
- import "../chunk-HEGTNY2S.js";
7
- import "../chunk-3TOCJOYJ.js";
6
+ import "../chunk-EWDSB24B.js";
7
+ import "../chunk-POBSY47Q.js";
8
8
  import "../chunk-EPBBYMNE.js";
9
- import "../chunk-CTKCGKWB.js";
10
- import "../chunk-CGZ6O74P.js";
11
- import "../chunk-3UUDZPO5.js";
9
+ import "../chunk-UOXATPSI.js";
10
+ import "../chunk-K2NCQJKH.js";
11
+ import "../chunk-YRPC6MJY.js";
12
12
  import "../chunk-CDQ4YIZM.js";
13
13
  import "../chunk-PDO5BLNM.js";
14
14
  import "../chunk-UIE3R5XU.js";
15
15
  import {
16
16
  loadAppPluginSet
17
17
  } from "../chunk-Y2CM7HXH.js";
18
- import "../chunk-76Y5A57F.js";
19
- import "../chunk-4ULSYOL6.js";
20
- import "../chunk-BTBTQEXF.js";
21
- import "../chunk-5I3MXBNV.js";
22
- import "../chunk-QE4DN7JQ.js";
18
+ import "../chunk-WPPXIAFB.js";
19
+ import "../chunk-ZFS67WIR.js";
20
+ import "../chunk-RB4NJKEX.js";
21
+ import "../chunk-5G34IEK2.js";
22
+ import "../chunk-UG6ZYPBI.js";
23
23
  import "../chunk-VFUK3X5B.js";
24
- import "../chunk-KRUSDASP.js";
25
- import "../chunk-QCX3TRIM.js";
26
- import "../chunk-IUSO5QUB.js";
27
- import "../chunk-4VDQGQHY.js";
24
+ import "../chunk-YNFERGKP.js";
25
+ import "../chunk-3Q342EJJ.js";
26
+ import "../chunk-36EG34YI.js";
27
+ import "../chunk-BZAMASJP.js";
28
28
  import "../chunk-77VDLF3Z.js";
29
29
  import "../chunk-HZF5P5UN.js";
30
30
  import "../chunk-F3B2YJ76.js";
31
- import "../chunk-BECYUPSQ.js";
31
+ import "../chunk-T6Z5S6PQ.js";
32
32
  import "../chunk-6GWA276C.js";
33
33
  import "../chunk-OOUNJNMR.js";
34
34
  import "../chunk-H4HBKISO.js";
35
- import "../chunk-ZIYDJIWQ.js";
36
- import "../chunk-DO37VD6O.js";
35
+ import "../chunk-5PNJMOY5.js";
36
+ import "../chunk-XZ7NPXAB.js";
37
37
  import "../chunk-MLKGABMK.js";
38
38
 
39
39
  // src/cli/chat.ts
@@ -156,10 +156,10 @@ async function configureLocalChatPlugins(pluginSet) {
156
156
  databaseModule
157
157
  ] = await Promise.all([
158
158
  import("../plugins-HW4VWW6G.js"),
159
- import("../agent-hooks-TQSI2FKN.js"),
160
- import("../catalog-runtime-VXL5EO2X.js"),
161
- import("../validation-EKUNT5IY.js"),
162
- import("../db-NN6T27OO.js")
159
+ import("../agent-hooks-MZOKEP3J.js"),
160
+ import("../catalog-runtime-MD66YLFV.js"),
161
+ import("../validation-ENHI7S2C.js"),
162
+ import("../db-66E7VDNC.js")
163
163
  ]);
164
164
  const resolvedPluginSet = pluginSet === void 0 ? await loadLocalPluginSet() : pluginSet ?? void 0;
165
165
  const plugins = pluginsModule.pluginRuntimeRegistrationsFromPluginSet(resolvedPluginSet);
@@ -223,8 +223,8 @@ function localDevServerUrl() {
223
223
  async function prepareLocalChatRun(io, pluginSet) {
224
224
  defaultStateAdapterForLocalChat();
225
225
  await configureLocalChatPlugins(pluginSet);
226
- const { runLocalAgentTurn } = await import("../runner-ZHI3GQII.js");
227
- const { startLocalOAuthCallbackServer } = await import("../oauth-callback-server-VJQ27ITN.js");
226
+ const { runLocalAgentTurn } = await import("../runner-L2BKJKOD.js");
227
+ const { startLocalOAuthCallbackServer } = await import("../oauth-callback-server-7QPD4Q7P.js");
228
228
  const { createLocalOAuthState } = await import("../oauth-relay-3ZU72UGL.js");
229
229
  const { createLocalSandboxEgressSignalTransport } = await import("../sandbox-egress-signals-A5HWIQH4.js");
230
230
  const agentRunner = createAgentRunner(executeAgentRun);
package/dist/cli/check.js CHANGED
@@ -1,15 +1,15 @@
1
1
  import {
2
2
  parseSkillFile
3
- } from "../chunk-QCX3TRIM.js";
4
- import "../chunk-IUSO5QUB.js";
3
+ } from "../chunk-3Q342EJJ.js";
4
+ import "../chunk-36EG34YI.js";
5
5
  import {
6
6
  parseInlinePluginManifest,
7
7
  parsePluginManifest
8
- } from "../chunk-4VDQGQHY.js";
8
+ } from "../chunk-BZAMASJP.js";
9
9
  import "../chunk-77VDLF3Z.js";
10
10
  import "../chunk-HZF5P5UN.js";
11
11
  import "../chunk-F3B2YJ76.js";
12
- import "../chunk-BECYUPSQ.js";
12
+ import "../chunk-T6Z5S6PQ.js";
13
13
  import "../chunk-6GWA276C.js";
14
14
  import "../chunk-OOUNJNMR.js";
15
15
  import "../chunk-H4HBKISO.js";
@@ -17,8 +17,8 @@ import {
17
17
  JUNIOR_CONVERSATION_WORK_CALLBACK_ROUTE,
18
18
  JUNIOR_HEARTBEAT_ROUTE,
19
19
  LEGACY_JUNIOR_CONVERSATION_WORK_FUNCTION
20
- } from "../chunk-ZIYDJIWQ.js";
21
- import "../chunk-DO37VD6O.js";
20
+ } from "../chunk-5PNJMOY5.js";
21
+ import "../chunk-XZ7NPXAB.js";
22
22
  import "../chunk-MLKGABMK.js";
23
23
 
24
24
  // src/cli/check.ts
@@ -637,7 +637,7 @@ async function validateAppSourceFiles(rootDir, registeredConfigKeys) {
637
637
  for (const keyMatch of block.matchAll(/["']([^"']+)["']\s*:/g)) {
638
638
  const key = keyMatch[1];
639
639
  if (key && !registeredConfigKeys.has(key)) {
640
- errors.push(
640
+ warnings.push(
641
641
  `${sourcePath}: configDefaults key "${key}" is not a registered plugin config key`
642
642
  );
643
643
  }
@@ -1,7 +1,7 @@
1
1
  import {
2
2
  validatePluginEgressCredentialHooks,
3
3
  validatePluginRegistrations
4
- } from "../chunk-2E5D3Z3U.js";
4
+ } from "../chunk-UZQ4VY3M.js";
5
5
  import {
6
6
  pluginCatalogConfigFromPluginSet,
7
7
  pluginCliRegistrationsFromPluginSet,
@@ -14,28 +14,28 @@ import {
14
14
  createPluginLogger,
15
15
  setPlugins,
16
16
  validatePlugins
17
- } from "../chunk-76Y5A57F.js";
17
+ } from "../chunk-WPPXIAFB.js";
18
18
  import {
19
19
  getDb
20
- } from "../chunk-4ULSYOL6.js";
21
- import "../chunk-BTBTQEXF.js";
22
- import "../chunk-5I3MXBNV.js";
23
- import "../chunk-QE4DN7JQ.js";
20
+ } from "../chunk-ZFS67WIR.js";
21
+ import "../chunk-RB4NJKEX.js";
22
+ import "../chunk-5G34IEK2.js";
23
+ import "../chunk-UG6ZYPBI.js";
24
24
  import "../chunk-VFUK3X5B.js";
25
- import "../chunk-KRUSDASP.js";
25
+ import "../chunk-YNFERGKP.js";
26
26
  import {
27
27
  pluginCatalogRuntime
28
- } from "../chunk-IUSO5QUB.js";
29
- import "../chunk-4VDQGQHY.js";
28
+ } from "../chunk-36EG34YI.js";
29
+ import "../chunk-BZAMASJP.js";
30
30
  import "../chunk-77VDLF3Z.js";
31
31
  import "../chunk-HZF5P5UN.js";
32
32
  import "../chunk-F3B2YJ76.js";
33
- import "../chunk-BECYUPSQ.js";
33
+ import "../chunk-T6Z5S6PQ.js";
34
34
  import "../chunk-6GWA276C.js";
35
35
  import "../chunk-OOUNJNMR.js";
36
36
  import "../chunk-H4HBKISO.js";
37
- import "../chunk-ZIYDJIWQ.js";
38
- import "../chunk-DO37VD6O.js";
37
+ import "../chunk-5PNJMOY5.js";
38
+ import "../chunk-XZ7NPXAB.js";
39
39
  import "../chunk-MLKGABMK.js";
40
40
 
41
41
  // src/cli/plugins.ts
@@ -1,25 +1,25 @@
1
1
  import {
2
2
  create,
3
3
  resolve
4
- } from "../chunk-CTKCGKWB.js";
4
+ } from "../chunk-UOXATPSI.js";
5
5
  import {
6
6
  disconnectStateAdapter
7
- } from "../chunk-5I3MXBNV.js";
8
- import "../chunk-QE4DN7JQ.js";
9
- import "../chunk-KRUSDASP.js";
7
+ } from "../chunk-5G34IEK2.js";
8
+ import "../chunk-UG6ZYPBI.js";
9
+ import "../chunk-YNFERGKP.js";
10
10
  import {
11
11
  pluginCatalogRuntime
12
- } from "../chunk-IUSO5QUB.js";
13
- import "../chunk-4VDQGQHY.js";
12
+ } from "../chunk-36EG34YI.js";
13
+ import "../chunk-BZAMASJP.js";
14
14
  import "../chunk-77VDLF3Z.js";
15
15
  import "../chunk-HZF5P5UN.js";
16
16
  import "../chunk-F3B2YJ76.js";
17
- import "../chunk-BECYUPSQ.js";
17
+ import "../chunk-T6Z5S6PQ.js";
18
18
  import "../chunk-6GWA276C.js";
19
19
  import "../chunk-OOUNJNMR.js";
20
20
  import "../chunk-H4HBKISO.js";
21
- import "../chunk-ZIYDJIWQ.js";
22
- import "../chunk-DO37VD6O.js";
21
+ import "../chunk-5PNJMOY5.js";
22
+ import "../chunk-XZ7NPXAB.js";
23
23
  import "../chunk-MLKGABMK.js";
24
24
 
25
25
  // src/cli/snapshot-create.ts