Use session IDs for scratches and queued messages (Vibe Kanban) (#1613)
* All changes have been completed. Here's a summary of what was done: ## Summary Changed both scratches and queued messages to use session IDs instead of workspace IDs: ### Files Modified 1. **`frontend/src/components/tasks/TaskFollowUpSection.tsx`** - Changed `useScratch(ScratchType.DRAFT_FOLLOW_UP, workspaceId ?? '')` → `useScratch(ScratchType.DRAFT_FOLLOW_UP, sessionId ?? '')` 2. **`crates/server/src/routes/sessions/queue.rs`** - Changed `session.workspace_id` → `session.id` in all three queue operations (queue, cancel, get status) 3. **`crates/services/src/services/queued_message.rs`** - Renamed `task_attempt_id` → `session_id` in `QueuedMessage` struct - Updated all method parameters and comments 4. **`crates/local-deployment/src/container.rs`** - Changed `ctx.workspace.id` → `ctx.session.id` for queue lookups and scratch deletion - Updated log messages to reference "session" instead of "workspace" 5. **`shared/types.ts`** (auto-generated) - `QueuedMessage.task_attempt_id` → `QueuedMessage.session_id` * Cleanup script changes for task attempt 4df90bcd-f261-41ca-bac3-8f7c2fc576c5 * Build passes. The fix has been applied. Found and fixed one missed instance in `sessions/mod.rs` where `Scratch::delete` was using `workspace.id` instead of `session.id`.
This commit is contained in:
@@ -133,7 +133,7 @@ export function TaskFollowUpSection({
|
||||
scratch,
|
||||
updateScratch,
|
||||
isLoading: isScratchLoading,
|
||||
} = useScratch(ScratchType.DRAFT_FOLLOW_UP, workspaceId ?? '');
|
||||
} = useScratch(ScratchType.DRAFT_FOLLOW_UP, sessionId ?? '');
|
||||
|
||||
// Derive the message and variant from scratch
|
||||
const scratchData: DraftFollowUpData | undefined =
|
||||
|
||||
Reference in New Issue
Block a user