@sentry/junior 0.76.0 → 0.76.1
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/app.js
CHANGED
|
@@ -71,7 +71,7 @@ import {
|
|
|
71
71
|
updateConversationStats,
|
|
72
72
|
uploadFilesToThread,
|
|
73
73
|
upsertConversationMessage
|
|
74
|
-
} from "./chunk-
|
|
74
|
+
} from "./chunk-FFGXUXMD.js";
|
|
75
75
|
import {
|
|
76
76
|
CONVERSATION_WORK_CHECK_IN_INTERVAL_MS,
|
|
77
77
|
CONVERSATION_WORK_STALE_ENQUEUE_MS,
|
|
@@ -2634,13 +2634,23 @@ function resolveReplyTimeoutMs(explicitTimeoutMs) {
|
|
|
2634
2634
|
const parsed = Number.parseInt(raw, 10);
|
|
2635
2635
|
return Number.isFinite(parsed) && parsed > 0 ? parsed : void 0;
|
|
2636
2636
|
}
|
|
2637
|
-
async function postSlackMessageBestEffort(channelId, threadTs, text) {
|
|
2637
|
+
async function postSlackMessageBestEffort(channelId, threadTs, text, footer) {
|
|
2638
2638
|
try {
|
|
2639
|
-
|
|
2640
|
-
|
|
2641
|
-
|
|
2642
|
-
|
|
2643
|
-
|
|
2639
|
+
if (footer) {
|
|
2640
|
+
await postSlackApiReplyPosts({
|
|
2641
|
+
channelId,
|
|
2642
|
+
threadTs,
|
|
2643
|
+
posts: [
|
|
2644
|
+
{
|
|
2645
|
+
text,
|
|
2646
|
+
stage: "thread_reply"
|
|
2647
|
+
}
|
|
2648
|
+
],
|
|
2649
|
+
footer
|
|
2650
|
+
});
|
|
2651
|
+
return;
|
|
2652
|
+
}
|
|
2653
|
+
await postSlackMessage({ channelId, threadTs, text });
|
|
2644
2654
|
} catch {
|
|
2645
2655
|
}
|
|
2646
2656
|
}
|
|
@@ -2691,6 +2701,9 @@ function getResumeLogContext(args, lockKey) {
|
|
|
2691
2701
|
modelId: botConfig.modelId
|
|
2692
2702
|
};
|
|
2693
2703
|
}
|
|
2704
|
+
function getResumeConversationId(args, lockKey) {
|
|
2705
|
+
return args.replyContext?.correlation?.conversationId ?? lockKey;
|
|
2706
|
+
}
|
|
2694
2707
|
async function postResumeFailureReply(args) {
|
|
2695
2708
|
try {
|
|
2696
2709
|
await postSlackMessage({
|
|
@@ -2853,7 +2866,7 @@ async function resumeSlackTurn(args) {
|
|
|
2853
2866
|
});
|
|
2854
2867
|
await status.stop();
|
|
2855
2868
|
const footer = buildSlackReplyFooter({
|
|
2856
|
-
conversationId: runArgs
|
|
2869
|
+
conversationId: getResumeConversationId(runArgs, lockKey)
|
|
2857
2870
|
});
|
|
2858
2871
|
await postSlackApiReplyPosts({
|
|
2859
2872
|
channelId: runArgs.channelId,
|
|
@@ -2950,13 +2963,17 @@ async function resumeSlackTurn(args) {
|
|
|
2950
2963
|
try {
|
|
2951
2964
|
await deferredPauseHandler();
|
|
2952
2965
|
if (deferredPauseKind === "auth" && deferredAuthInfo) {
|
|
2966
|
+
const footer = buildSlackReplyFooter({
|
|
2967
|
+
conversationId: getResumeConversationId(runArgs, lockKey)
|
|
2968
|
+
});
|
|
2953
2969
|
await postSlackMessageBestEffort(
|
|
2954
2970
|
runArgs.channelId,
|
|
2955
2971
|
runArgs.threadTs,
|
|
2956
2972
|
buildAuthPauseResponse(
|
|
2957
2973
|
deferredAuthInfo.requesterId,
|
|
2958
2974
|
deferredAuthInfo.providerDisplayName
|
|
2959
|
-
)
|
|
2975
|
+
),
|
|
2976
|
+
footer
|
|
2960
2977
|
);
|
|
2961
2978
|
}
|
|
2962
2979
|
return true;
|
|
@@ -9531,16 +9548,29 @@ function createReplyToThread(deps) {
|
|
|
9531
9548
|
await options.beforeFirstResponsePost?.();
|
|
9532
9549
|
};
|
|
9533
9550
|
const postAuthPauseNotice = async (providerDisplayName) => {
|
|
9551
|
+
const text = buildAuthPauseResponse(
|
|
9552
|
+
message.author.userId,
|
|
9553
|
+
providerDisplayName
|
|
9554
|
+
);
|
|
9555
|
+
const footer = buildSlackReplyFooter({ conversationId });
|
|
9534
9556
|
try {
|
|
9535
|
-
|
|
9536
|
-
|
|
9537
|
-
|
|
9538
|
-
|
|
9539
|
-
|
|
9540
|
-
|
|
9541
|
-
|
|
9542
|
-
|
|
9543
|
-
|
|
9557
|
+
if (channelId && threadTs) {
|
|
9558
|
+
await postSlackApiReplyPosts({
|
|
9559
|
+
beforePost: beforeFirstResponsePost,
|
|
9560
|
+
channelId,
|
|
9561
|
+
threadTs,
|
|
9562
|
+
posts: [
|
|
9563
|
+
{
|
|
9564
|
+
text,
|
|
9565
|
+
stage: "thread_reply"
|
|
9566
|
+
}
|
|
9567
|
+
],
|
|
9568
|
+
footer
|
|
9569
|
+
});
|
|
9570
|
+
} else {
|
|
9571
|
+
await beforeFirstResponsePost();
|
|
9572
|
+
await thread.post(buildSlackOutputMessage(text));
|
|
9573
|
+
}
|
|
9544
9574
|
} catch (error) {
|
|
9545
9575
|
logException(
|
|
9546
9576
|
error,
|
|
@@ -25,7 +25,7 @@ export interface SlackReplyFooter {
|
|
|
25
25
|
items: SlackReplyFooterItem[];
|
|
26
26
|
}
|
|
27
27
|
/**
|
|
28
|
-
* Build the compact conversation footer for
|
|
28
|
+
* Build the compact conversation footer for visible Slack reply surfaces.
|
|
29
29
|
*
|
|
30
30
|
* Detailed turn metrics stay in the dashboard instead of Slack-visible copy.
|
|
31
31
|
*/
|
|
@@ -11839,11 +11839,15 @@ async function generateAssistantReply(messageText2, context) {
|
|
|
11839
11839
|
promptGuidelines: definition.promptGuidelines,
|
|
11840
11840
|
promptSnippet: definition.promptSnippet
|
|
11841
11841
|
}));
|
|
11842
|
+
const pendingMcpProvider = context.pendingAuth?.kind === "mcp" ? context.pendingAuth.provider : void 0;
|
|
11842
11843
|
const providersToRestore = /* @__PURE__ */ new Set([
|
|
11843
11844
|
...connectedMcpProviders,
|
|
11844
11845
|
...inferActiveMcpProvidersFromPiMessages(priorPiMessages)
|
|
11845
11846
|
]);
|
|
11846
11847
|
for (const provider of providersToRestore) {
|
|
11848
|
+
if (provider === pendingMcpProvider) {
|
|
11849
|
+
continue;
|
|
11850
|
+
}
|
|
11847
11851
|
if (await turnMcpToolManager.activateProvider(provider)) {
|
|
11848
11852
|
await recordConnectedMcpProvider(provider);
|
|
11849
11853
|
}
|
|
@@ -11853,6 +11857,9 @@ async function generateAssistantReply(messageText2, context) {
|
|
|
11853
11857
|
}
|
|
11854
11858
|
}
|
|
11855
11859
|
for (const skill of activeSkills) {
|
|
11860
|
+
if (skill.pluginProvider === pendingMcpProvider) {
|
|
11861
|
+
continue;
|
|
11862
|
+
}
|
|
11856
11863
|
if (await turnMcpToolManager.activateForSkill(skill)) {
|
|
11857
11864
|
await recordConnectedMcpProvider(skill.pluginProvider);
|
|
11858
11865
|
}
|
package/dist/cli/chat.js
CHANGED
|
@@ -193,7 +193,7 @@ async function runPrompt(options, io, pluginSet) {
|
|
|
193
193
|
defaultStateAdapterForLocalChat();
|
|
194
194
|
await configureLocalChatPlugins(pluginSet);
|
|
195
195
|
const conversationId = newRunConversationId();
|
|
196
|
-
const { runLocalAgentTurn } = await import("../runner-
|
|
196
|
+
const { runLocalAgentTurn } = await import("../runner-7Z4D6AKV.js");
|
|
197
197
|
const result = await runLocalAgentTurn(
|
|
198
198
|
{
|
|
199
199
|
conversationId,
|
|
@@ -217,7 +217,7 @@ async function runInteractive(io, pluginSet) {
|
|
|
217
217
|
defaultStateAdapterForLocalChat();
|
|
218
218
|
await configureLocalChatPlugins(pluginSet);
|
|
219
219
|
const conversationId = newRunConversationId();
|
|
220
|
-
const { runLocalAgentTurn } = await import("../runner-
|
|
220
|
+
const { runLocalAgentTurn } = await import("../runner-7Z4D6AKV.js");
|
|
221
221
|
const rl = readline.createInterface({
|
|
222
222
|
input: io.input,
|
|
223
223
|
output: io.output,
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@sentry/junior",
|
|
3
|
-
"version": "0.76.
|
|
3
|
+
"version": "0.76.1",
|
|
4
4
|
"private": false,
|
|
5
5
|
"publishConfig": {
|
|
6
6
|
"access": "public"
|
|
@@ -70,7 +70,7 @@
|
|
|
70
70
|
"pg": "^8.16.3",
|
|
71
71
|
"yaml": "^2.9.0",
|
|
72
72
|
"zod": "^4.4.3",
|
|
73
|
-
"@sentry/junior-plugin-api": "0.76.
|
|
73
|
+
"@sentry/junior-plugin-api": "0.76.1"
|
|
74
74
|
},
|
|
75
75
|
"devDependencies": {
|
|
76
76
|
"@emnapi/core": "^1.10.0",
|
|
@@ -86,9 +86,9 @@
|
|
|
86
86
|
"typescript": "^6.0.3",
|
|
87
87
|
"vercel": "^54.4.0",
|
|
88
88
|
"vitest": "^4.1.7",
|
|
89
|
-
"@sentry/junior-
|
|
90
|
-
"@sentry/junior-
|
|
91
|
-
"@sentry/junior-
|
|
89
|
+
"@sentry/junior-memory": "0.76.1",
|
|
90
|
+
"@sentry/junior-scheduler": "0.76.1",
|
|
91
|
+
"@sentry/junior-testing": "0.0.0"
|
|
92
92
|
},
|
|
93
93
|
"scripts": {
|
|
94
94
|
"build": "tsup && tsc -p tsconfig.build.json --emitDeclarationOnly",
|