fix(core): soft-delete source connections with deleted_at

Migration 0003 adds source_connections.deleted_at. deleteConnection sets it; listing, lookups,
updates, the scheduler and the sync handler ignore deleted connections, so a paused
credential-less connection stays visible and can be resumed.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
Lucas WintherandClaude Opus 5.5 committed 2026-10-30 21:25:59 +01:00
1 parent 0a540208e1
commit e3a759d768
8 files changed
+81 -16

No files matched your search

+1 -2
View File
@@ -4,7 +4,6 @@ import {
devicePoll,
deviceStart,
getConnection,
isDeletedConnection,
listConnections,
listRuns,
updateConnection,
@@ -48,7 +47,7 @@ export const sourceRoutes = [
path: "sources",
summary: "Your source connections (never includes secrets).",
auth: "any:read",
handler: async ({ deps, user }) => (await listConnections(deps.db, user.id)).filter((c) => !isDeletedConnection(c)),
handler: async ({ deps, user }) => listConnections(deps.db, user.id),
}),
route({
method: "POST",