Feat/daytona sandbox sync#65
Conversation
|
@claude review this |
|
Claude finished @jon3350's task in 2m 55s —— View job PR Review: Feat/daytona sandbox sync
This is a large PR (~26k lines across 100 files) introducing Daytona sandbox integration, a command palette, slash commands, rate limiting, usage display, harness-creation assistant, and a comprehensive test suite. The overall architecture is solid, but there are a few security and correctness issues worth addressing before merge. Security Issues1. Missing auth on
// commands.ts:56 — no identity check before returning data
export const getByIds = query({
args: { ids: v.array(v.id("commands")) },
handler: async (ctx, args) => {
const results = await Promise.all(args.ids.map((id) => ctx.db.get(id)));
return results.filter(Boolean); // ← no auth guard
},
});2. Command name collision between users in
Architecture & Correctness Issues3. SSE
Additionally, silently swallowing JSON parse errors at line 229–231 makes production debugging very hard. Consider logging at // line 229-232 — both issues visible here
} catch {
// Skip malformed JSON lines ← no log, no trace
}
currentEvent = "message"; // ← should reset on blank line, not hereFix this →%20currentEvent%20is%20reset%20to%20%22message%22%20after%20each%20data%3A%20line%20(line%20232)%20but%20per%20SSE%20spec%20it%20should%20only%20reset%20on%20blank-line%20event%20dispatch.%202)%20JSON%20parse%20errors%20(line%20229)%20are%20silently%20swallowed%20%E2%80%94%20add%20console.warn%20so%20protocol%20bugs%20are%20visible.%20Fix%20by%20tracking%20currentData%20buffer%20and%20dispatching%20on%20blank%20lines.%20Branch%3A%20feat%2Fdaytona-sandbox-sync&repo=DIodide/Harness) 4. Blob URL memory leak in
5. OAuth window name collision in
6. Conversations truncated silently in fork operations [Low]
Privacy / Data Governance7. Full conversation content stored in ratings [Low]
Minor Notes
What's Good
|
|
@claude I meant to merge into stagging, not main. Can you review again. |
|
Claude finished @jon3350's task in 3m 2s —— View job PR Review: Feat/daytona sandbox sync (vs
|
…ync etc. we rely on LRU cache and timeout to stop sandboxes ourselves
No description provided.