@sentry/junior 0.298.0 → 0.300.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/{actor-6jsm_v96.js → actor-D2iXzvlN.js} +2 -1
- package/dist/{state-CSuA2J1V.js → adapter-S5UkjNK3.js} +53 -136
- package/dist/{admin-BF3DbYGf.js → admin-UrTniSPO.js} +2 -2
- package/dist/{agent-runner-Q9GkoerG.js → agent-runner-bY4_0UPm.js} +1444 -1478
- package/dist/api/schema.d.ts +2 -2
- package/dist/api/schema.js +7 -7
- package/dist/api.d.ts +1 -1
- package/dist/api.js +382 -68
- package/dist/{app-DOg_mCtV.d.ts → app-D-AcIcCV.d.ts} +17 -4
- package/dist/app.d.ts +1 -1
- package/dist/app.js +148 -483
- package/dist/{automation-Cn8qmbdr.js → automation-Dw82oQ-h.js} +2 -2
- package/dist/{background-compaction-queue-BZhGFOK6.js → background-compaction-queue-B6U3060-.js} +9 -5
- package/dist/{briefs-CQrCRF6-.js → briefs-DqiwWu-n.js} +4 -4
- package/dist/{catalog-runtime-DZeD2WbL.js → catalog-runtime-D1oYNv04.js} +1 -1
- package/dist/cli/chat.js +17 -17
- package/dist/cli/check.js +3 -3
- package/dist/cli/main.js +3 -3
- package/dist/cli/plugins.js +5 -5
- package/dist/cli/snapshot-create.js +4 -4
- package/dist/cli/upgrade.d.ts +1 -1
- package/dist/cli/upgrade.js +4 -4
- package/dist/{config-BOByVnxe.js → config-9nHoFiJP.js} +117 -12
- package/dist/{connections-BNN5cJam.js → connections-DZjTN3JC.js} +6 -6
- package/dist/continue-in-slack-Dtv7_U42.js +176 -0
- package/dist/{conversation-DCkzvxqB.js → conversation-Dyjq2CZ8.js} +36 -13
- package/dist/{conversation-feed-CMA12Rjs.js → conversation-feed-CcDxlrlQ.js} +109 -3
- package/dist/{conversation-privacy-C0eRxsgb.js → conversation-privacy-D-5HTXjS.js} +1 -1
- package/dist/{conversation-turn-D9qvcDX6.js → conversation-turn-Cxl8WZD7.js} +85 -68
- package/dist/{credential-sync-B_iUpxGL.js → credential-sync-C49ClwDX.js} +18 -18
- package/dist/{db-DoMcnYol.d.ts → db-2resqBh1.d.ts} +1 -1
- package/dist/{db-CoMNr2Zm.js → db-BJNo6fK5.js} +176 -12
- package/dist/{executor-C-m8VrzX.js → executor-DBIaOeJ_.js} +47 -13
- package/dist/{media-BepyEUNm.js → history-IjdmO_r6.js} +1 -85
- package/dist/instrumentation.js +14 -5
- package/dist/lineage-0dereG7H.js +37 -0
- package/dist/{logging-CJTi5niy.js → logging-BIclibct.js} +1 -1
- package/dist/{message-Q6_5DAWR.js → message-dkOl-Iii.js} +9 -10
- package/dist/model-input-CLo9TaUd.js +82 -0
- package/dist/nitro.d.ts +1 -1
- package/dist/nitro.js +17 -9
- package/dist/{oauth-callback-server-CH5XAyo-.js → oauth-callback-server-WmpjfJgQ.js} +2 -2
- package/dist/{plugins-HYh_JOdw.js → plugins-BBX07Jzt.js} +1 -1
- package/dist/{projection-BgwEE36_.js → projection-w_X-zi7v.js} +1035 -692
- package/dist/{prompt-DXc9DYT9.js → prompt-B1Xw46-S.js} +4 -4
- package/dist/{registry-9XwqSnM-.js → registry-BmP5vnlj.js} +4 -4
- package/dist/{resolve-DUIAbcRL.js → resolve-goo34bJK.js} +3 -3
- package/dist/{result-C2Vn8QGn.js → result-PVBeU0Wf.js} +158 -69
- package/dist/{runner-CXGtw-Mc.js → runner-DKrfvNV6.js} +9 -9
- package/dist/{sandbox-egress-signals-Di3S_dO7.js → sandbox-egress-signals-DsUcqrI0.js} +1 -1
- package/dist/{schema-Dyp7racy.js → schema-C9iNFz5n.js} +51 -7
- package/dist/{schema-BnbZ-rKv.d.ts → schema-Dns-sTas.d.ts} +1285 -761
- package/dist/{service-account-DM3KBBeG.js → service-account-CMAAloAL.js} +3 -3
- package/dist/{service-account-GzAMUQ8a.js → service-account-CmowamcB.js} +4 -4
- package/dist/session-stop-BcAXze8a.js +3330 -0
- package/dist/{skills-DCK9SD_l.js → skills-DfsazET6.js} +3 -3
- package/dist/slack-conversation-unfurl-CzQonuWz.js +370 -0
- package/dist/spawn-C7o0FDDp.js +73 -0
- package/dist/state-zSilNpbi.js +132 -0
- package/dist/{user-input-request-CXNIov9n.js → statuses-Hn-HsOph.js} +115 -26
- package/dist/{stop-Dh2DfwpK.js → stop-CFOujp8C.js} +9105 -6007
- package/dist/{store-DrA17Fbz.js → store-Dkeis_8o.js} +10 -10
- package/dist/{store-B1zepKG8.js → store-E3x2Fg_F.js} +24 -4
- package/dist/{task-queue-D1rXWfFN.js → task-queue-D-hCqdZW.js} +4 -4
- package/dist/{task-runner-CT4M8oDz.js → task-runner-vohUPLHe.js} +10 -10
- package/dist/{thread-context-DnqUkbzN.js → thread-context-BzvdkgI9.js} +18 -18
- package/dist/{turn-session-routing-VXDVXLRl.js → turn-session-routing-Bo_LxFum.js} +5 -5
- package/dist/turn-user-message-D5RnVmxQ.js +355 -0
- package/dist/users-2bggndVg.js +424 -0
- package/dist/{validation-zxAJBDDy.js → validation-BbWikeSa.js} +1 -1
- package/dist/{version-DcZ40a0g.js → version-GVBMW2jA.js} +1 -1
- package/dist/version.js +1 -1
- package/dist/{viewer-CgiGjW10.js → viewer-BpxRliyO.js} +36 -163
- package/dist/{warmup-CwKbxQLl.js → warmup-BW2qwnal.js} +1140 -145
- package/dist/{worker-CbDUzaBA.js → worker-Cbd-iuwZ.js} +25 -20
- package/migrations/0104_code_change_draft.sql +1 -0
- package/migrations/0105_attachment_uploads.sql +14 -0
- package/migrations/0106_conversation_agent_config.sql +1 -0
- package/migrations/0107_attachment_deferred_download.sql +2 -0
- package/migrations/meta/0104_snapshot.json +4516 -0
- package/migrations/meta/0105_snapshot.json +4611 -0
- package/migrations/meta/0106_snapshot.json +4617 -0
- package/migrations/meta/0107_snapshot.json +4617 -0
- package/migrations/meta/_journal.json +28 -0
- package/package.json +10 -8
- package/dist/attempt-selection-ClP3MMPr.js +0 -61
- package/dist/locks-D-0h111u.js +0 -48
- package/dist/notification-Bv25xbj0.js +0 -1284
- package/dist/prompt-input-BUr4J9RO.js +0 -1424
- package/dist/session-stop-D4i7e6iT.js +0 -181
- package/dist/spawn-6cX6xE9G.js +0 -80
- package/dist/turn-cancel-l460pfGW.js +0 -201
- package/dist/turn-user-message-BSPmkm7X.js +0 -608
- package/dist/turn-wake-DVFVXyhX.js +0 -161
- package/dist/{oauth-relay-CsfIazeF.js → oauth-relay-DRzq73b6.js} +1 -1
|
@@ -1,30 +1,23 @@
|
|
|
1
1
|
import { v as __exportAll } from "./sentry-BRTJqumy.js";
|
|
2
|
-
import {
|
|
3
|
-
import {
|
|
4
|
-
import { T as withLogContext, b as setSpanAttributes, h as logWarn, m as logInfo, p as logException } from "./logging-
|
|
5
|
-
import {
|
|
6
|
-
import {
|
|
7
|
-
import {
|
|
8
|
-
import { i as
|
|
9
|
-
// src/chat/task-execution/
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
const CONVERSATION_WORK_DEFER_DELAY_MS = 15e3;
|
|
15
|
-
const CONVERSATION_STOP_CHECK_INTERVAL_MS = 500;
|
|
16
|
-
function now(options) {
|
|
17
|
-
return options.nowMs?.() ?? Date.now();
|
|
18
|
-
}
|
|
19
|
-
function nudgeIdempotencyKey(reason, conversationId, nowMs) {
|
|
20
|
-
return `${reason}:${conversationId}:${nowMs}`;
|
|
21
|
-
}
|
|
2
|
+
import { Ct as countPendingConversationMessages, Nt as isFinalAttempt, Pt as isInvalidConversationRecordError, jt as hasConversationStop } from "./projection-w_X-zi7v.js";
|
|
3
|
+
import { i as getChatConfig, q as isProviderRetryError } from "./config-9nHoFiJP.js";
|
|
4
|
+
import { T as withLogContext, b as setSpanAttributes, h as logWarn, m as logInfo, p as logException } from "./logging-BIclibct.js";
|
|
5
|
+
import { t as getConversationStoppedAtMs } from "./session-stop-BcAXze8a.js";
|
|
6
|
+
import { bt as isAttemptInterrupt, xt as selectAttemptMessages } from "./warmup-BW2qwnal.js";
|
|
7
|
+
import { T as getTurnRequestDeadline, f as ConversationQueueMessageRejectedError, h as nudgeIdempotencyKey } from "./background-compaction-queue-B6U3060-.js";
|
|
8
|
+
import { C as requestAnotherSlice, S as releaseConversationWork, T as startConversationWork, _ as getConversationWorkState, b as recordAttemptFailure, c as clearConsumedConversationWake, d as completeConversationWork, f as deadLetterAttempt, h as ensureConversationWake, i as beginConversationResume, o as checkInConversationWork, p as drainConversationMailbox, t as ackMessages, u as completeConversationStop, x as recordConversationRetry } from "./store-E3x2Fg_F.js";
|
|
9
|
+
// src/chat/task-execution/lost-lease.ts
|
|
10
|
+
/**
|
|
11
|
+
* Count a slice that lost its Conversation Lease as a failed attempt, then
|
|
12
|
+
* hand the work to a new slice, or stop it when retries are exhausted.
|
|
13
|
+
*/
|
|
22
14
|
async function requestLostLeaseRecovery(args) {
|
|
23
15
|
const before = await getConversationWorkState({
|
|
24
16
|
conversationId: args.conversationId,
|
|
25
17
|
state: args.options.state
|
|
26
18
|
});
|
|
27
19
|
const retry = await recordConversationRetry({
|
|
20
|
+
beforeWorkStops: args.options.beforeWorkStops,
|
|
28
21
|
conversationId: args.conversationId,
|
|
29
22
|
leaseToken: args.leaseToken,
|
|
30
23
|
conversationStore: args.options.conversationStore,
|
|
@@ -65,6 +58,16 @@ async function requestLostLeaseRecovery(args) {
|
|
|
65
58
|
state: args.options.state
|
|
66
59
|
});
|
|
67
60
|
}
|
|
61
|
+
// src/chat/task-execution/worker.ts
|
|
62
|
+
var worker_exports = /* @__PURE__ */ __exportAll({
|
|
63
|
+
CONVERSATION_WORK_DEFER_DELAY_MS: () => CONVERSATION_WORK_DEFER_DELAY_MS,
|
|
64
|
+
processConversationWork: () => processConversationWork
|
|
65
|
+
});
|
|
66
|
+
const CONVERSATION_WORK_DEFER_DELAY_MS = 15e3;
|
|
67
|
+
const CONVERSATION_STOP_CHECK_INTERVAL_MS = 500;
|
|
68
|
+
function now(options) {
|
|
69
|
+
return options.nowMs?.() ?? Date.now();
|
|
70
|
+
}
|
|
68
71
|
/**
|
|
69
72
|
* Record one failed delivery attempt and surface dead-lettered messages.
|
|
70
73
|
*
|
|
@@ -528,6 +531,7 @@ async function processConversationWorkInContext(message, options) {
|
|
|
528
531
|
madeProgress: !failedWithoutProgress,
|
|
529
532
|
resumeIfStopped,
|
|
530
533
|
conversationStore: options.conversationStore,
|
|
534
|
+
getSlackAdapter: options.getSlackAdapter,
|
|
531
535
|
nowMs: now(options),
|
|
532
536
|
state: options.state
|
|
533
537
|
});
|
|
@@ -588,6 +592,7 @@ async function processConversationWorkInContext(message, options) {
|
|
|
588
592
|
});
|
|
589
593
|
} else {
|
|
590
594
|
if ((failure ? failure.status : await recordConversationRetry({
|
|
595
|
+
beforeWorkStops: options.beforeWorkStops,
|
|
591
596
|
conversationId,
|
|
592
597
|
leaseToken: lease.leaseToken,
|
|
593
598
|
conversationStore: options.conversationStore,
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
ALTER TABLE "junior_code_changes" ADD COLUMN "draft" boolean DEFAULT false NOT NULL;
|
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
CREATE TABLE "junior_attachment_uploads" (
|
|
2
|
+
"id" text PRIMARY KEY NOT NULL,
|
|
3
|
+
"conversation_id" text NOT NULL,
|
|
4
|
+
"user_id" text NOT NULL,
|
|
5
|
+
"idempotency_key" text NOT NULL,
|
|
6
|
+
"storage_provider" text NOT NULL,
|
|
7
|
+
"storage_key" text NOT NULL,
|
|
8
|
+
"filename" text NOT NULL,
|
|
9
|
+
"content_type" text NOT NULL,
|
|
10
|
+
"bytes" integer NOT NULL,
|
|
11
|
+
"created_at" timestamp with time zone NOT NULL
|
|
12
|
+
);
|
|
13
|
+
--> statement-breakpoint
|
|
14
|
+
CREATE INDEX "junior_attachment_uploads_gc_idx" ON "junior_attachment_uploads" USING btree ("storage_provider","created_at");
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
ALTER TABLE "junior_conversations" ADD COLUMN "agent_config_json" jsonb;
|