Add guarded worktree convergence

This commit is contained in:
thePR0M3TH3AN committed 2026-09-27 17:56:34 -04:00
1 parent b015c6a758
commit 104f5f4469
8 files changed
+294 -5

No files matched your search

+7
View File
@@ -100,6 +100,13 @@ export function diagnoseProject({ repository, env = process.env }) {
`).all();
if (requests.length) findings.push({ severity: 'info', code: 'INTEGRATION_QUEUE', requests });
}
if (hasTable('worktree_guards')) {
const guards = database.prepare(`
SELECT area_id AS areaId, guard_type AS type, reason, created_at AS createdAt
FROM worktree_guards WHERE released_at IS NULL ORDER BY created_at, id
`).all();
if (guards.length) findings.push({ severity: 'info', code: 'WORKTREE_GUARDS', guards });
}
database.close();
} catch (error) {
findings.push({ severity: 'error', code: 'CONTROL_PLANE_INVALID', path: databasePath, message: error.message });