fix: restore Claude Code in provider picker, preserve turn error status, deduplicate summarizeToolOutput call
- Add Claude Code back to COMING_SOON_PROVIDER_OPTIONS so it renders with a 'Coming soon' badge instead of vanishing from the picker - Remove redundant session status/activeTurnId/updatedAt overwrite in sendTurn that was masking the error status set by completeTurn - Cache summarizeToolOutput result in a local variable to avoid calling the function twice on the same input Co-authored-by: Julius Marminge <[email protected]>
This commit is contained in:
1 parent
05f4cb216b
commit
7ffed19c49
2 files changed
+3
-6
No files matched your search
@@ -752,6 +752,7 @@ function makeCursorAdapter(options?: CursorAdapterLiveOptions) {
|
||||
const title = trackedTool?.title ?? titleForItemType(itemType);
|
||||
const stamp = yield* makeEventStamp();
|
||||
const eventType = update.status === "completed" ? "item.completed" : "item.updated";
|
||||
const toolSummary = summarizeToolOutput(update.rawOutput);
|
||||
yield* offerRuntimeEvent({
|
||||
...base,
|
||||
type: eventType,
|
||||
@@ -763,9 +764,7 @@ function makeCursorAdapter(options?: CursorAdapterLiveOptions) {
|
||||
itemType,
|
||||
status,
|
||||
title,
|
||||
...(summarizeToolOutput(update.rawOutput)
|
||||
? { detail: summarizeToolOutput(update.rawOutput) }
|
||||
: {}),
|
||||
...(toolSummary ? { detail: toolSummary } : {}),
|
||||
...(update.rawOutput !== undefined ? { data: update.rawOutput } : {}),
|
||||
},
|
||||
});
|
||||
@@ -1351,9 +1350,6 @@ function makeCursorAdapter(options?: CursorAdapterLiveOptions) {
|
||||
|
||||
context.session = {
|
||||
...context.session,
|
||||
status: "ready",
|
||||
activeTurnId: undefined,
|
||||
updatedAt: yield* nowIso,
|
||||
resumeCursor: {
|
||||
acpSessionId: context.acpSessionId,
|
||||
},
|
||||
|
||||
@@ -5280,6 +5280,7 @@ const MessagesTimeline = memo(function MessagesTimeline({
|
||||
|
||||
const AVAILABLE_PROVIDER_OPTIONS = PROVIDER_OPTIONS.filter((option) => option.available);
|
||||
const COMING_SOON_PROVIDER_OPTIONS = [
|
||||
{ id: "claudeCode", label: "Claude Code", icon: ClaudeAI },
|
||||
{ id: "opencode", label: "OpenCode", icon: OpenCodeIcon },
|
||||
{ id: "gemini", label: "Gemini", icon: Gemini },
|
||||
] as const;
|
||||
|
||||
Reference in new issue
Block a user