merge main and fix CI: add plugin build step to pr-checks workflow
Merges origin/main to bring in the droid runtime plugin (needed by plugin-loader test) and all recent changes. Adds a "Build plugins" step to pr-checks.yml so plugin dist/ directories are compiled before tests run — fixes ERR_MODULE_NOT_FOUND for hermes and droid plugins. Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
This commit is contained in:
@@ -88,7 +88,7 @@ export function probeFts5(db: DatabaseSync): boolean {
|
||||
|
||||
// ── Schema Definition ────────────────────────────────────────────────
|
||||
|
||||
const SCHEMA_VERSION = 59;
|
||||
const SCHEMA_VERSION = 60;
|
||||
|
||||
function normalizeTaskComments(
|
||||
steeringComments: SteeringComment[] | undefined,
|
||||
@@ -215,6 +215,7 @@ CREATE TABLE IF NOT EXISTS tasks (
|
||||
missionId TEXT,
|
||||
sliceId TEXT,
|
||||
assignedAgentId TEXT,
|
||||
pausedByAgentId TEXT,
|
||||
assigneeUserId TEXT,
|
||||
sourceType TEXT,
|
||||
sourceAgentId TEXT,
|
||||
@@ -419,6 +420,8 @@ CREATE TABLE IF NOT EXISTS research_runs (
|
||||
query TEXT NOT NULL,
|
||||
topic TEXT,
|
||||
status TEXT NOT NULL,
|
||||
projectId TEXT,
|
||||
trigger TEXT,
|
||||
providerConfig TEXT,
|
||||
sources TEXT NOT NULL DEFAULT '[]',
|
||||
events TEXT NOT NULL DEFAULT '[]',
|
||||
@@ -427,6 +430,7 @@ CREATE TABLE IF NOT EXISTS research_runs (
|
||||
tokenUsage TEXT,
|
||||
tags TEXT NOT NULL DEFAULT '[]',
|
||||
metadata TEXT,
|
||||
lifecycle TEXT,
|
||||
createdAt TEXT NOT NULL,
|
||||
updatedAt TEXT NOT NULL,
|
||||
startedAt TEXT,
|
||||
@@ -448,6 +452,20 @@ CREATE TABLE IF NOT EXISTS research_exports (
|
||||
);
|
||||
CREATE INDEX IF NOT EXISTS idxResearchExportsRunId ON research_exports(runId);
|
||||
|
||||
CREATE TABLE IF NOT EXISTS research_run_events (
|
||||
id TEXT PRIMARY KEY,
|
||||
runId TEXT NOT NULL,
|
||||
seq INTEGER NOT NULL,
|
||||
type TEXT NOT NULL,
|
||||
message TEXT NOT NULL,
|
||||
status TEXT,
|
||||
classification TEXT,
|
||||
metadata TEXT,
|
||||
createdAt TEXT NOT NULL,
|
||||
FOREIGN KEY (runId) REFERENCES research_runs(id) ON DELETE CASCADE
|
||||
);
|
||||
CREATE INDEX IF NOT EXISTS idxResearchRunEventsRunIdSeq ON research_run_events(runId, seq);
|
||||
|
||||
-- Schema version tracking
|
||||
CREATE TABLE IF NOT EXISTS __meta (
|
||||
key TEXT PRIMARY KEY,
|
||||
@@ -643,9 +661,11 @@ CREATE TABLE IF NOT EXISTS project_insight_runs (
|
||||
insightsUpdated INTEGER NOT NULL DEFAULT 0,
|
||||
inputMetadata TEXT,
|
||||
outputMetadata TEXT,
|
||||
lifecycle TEXT,
|
||||
createdAt TEXT NOT NULL,
|
||||
startedAt TEXT,
|
||||
completedAt TEXT
|
||||
completedAt TEXT,
|
||||
cancelledAt TEXT
|
||||
);
|
||||
|
||||
-- Index for filtering insights by projectId
|
||||
@@ -663,6 +683,23 @@ CREATE INDEX IF NOT EXISTS idxProjectInsightsCategory
|
||||
-- Index for filtering runs by projectId
|
||||
CREATE INDEX IF NOT EXISTS idxInsightRunsProjectId
|
||||
ON project_insight_runs(projectId);
|
||||
CREATE INDEX IF NOT EXISTS idxInsightRunsProjectTriggerStatus
|
||||
ON project_insight_runs(projectId, trigger, status);
|
||||
|
||||
CREATE TABLE IF NOT EXISTS project_insight_run_events (
|
||||
id TEXT PRIMARY KEY,
|
||||
runId TEXT NOT NULL,
|
||||
seq INTEGER NOT NULL,
|
||||
type TEXT NOT NULL,
|
||||
message TEXT NOT NULL,
|
||||
status TEXT,
|
||||
classification TEXT,
|
||||
metadata TEXT,
|
||||
createdAt TEXT NOT NULL,
|
||||
FOREIGN KEY (runId) REFERENCES project_insight_runs(id) ON DELETE CASCADE
|
||||
);
|
||||
CREATE INDEX IF NOT EXISTS idxInsightRunEventsRunIdSeq
|
||||
ON project_insight_run_events(runId, seq);
|
||||
|
||||
-- Todo list persistence tables (FN-2575)
|
||||
-- Project-scoped todo lists and ordered checklist items
|
||||
@@ -1828,9 +1865,11 @@ export class Database {
|
||||
insightsUpdated INTEGER NOT NULL DEFAULT 0,
|
||||
inputMetadata TEXT,
|
||||
outputMetadata TEXT,
|
||||
lifecycle TEXT,
|
||||
createdAt TEXT NOT NULL,
|
||||
startedAt TEXT,
|
||||
completedAt TEXT
|
||||
completedAt TEXT,
|
||||
cancelledAt TEXT
|
||||
)
|
||||
`);
|
||||
|
||||
@@ -2194,6 +2233,8 @@ export class Database {
|
||||
query TEXT NOT NULL,
|
||||
topic TEXT,
|
||||
status TEXT NOT NULL,
|
||||
projectId TEXT,
|
||||
trigger TEXT,
|
||||
providerConfig TEXT,
|
||||
sources TEXT NOT NULL DEFAULT '[]',
|
||||
events TEXT NOT NULL DEFAULT '[]',
|
||||
@@ -2202,6 +2243,7 @@ export class Database {
|
||||
tokenUsage TEXT,
|
||||
tags TEXT NOT NULL DEFAULT '[]',
|
||||
metadata TEXT,
|
||||
lifecycle TEXT,
|
||||
createdAt TEXT NOT NULL,
|
||||
updatedAt TEXT NOT NULL,
|
||||
startedAt TEXT,
|
||||
@@ -2213,6 +2255,7 @@ export class Database {
|
||||
this.db.exec(`CREATE INDEX IF NOT EXISTS idxResearchRunsStatus ON research_runs(status)`);
|
||||
this.db.exec(`CREATE INDEX IF NOT EXISTS idxResearchRunsCreatedAt ON research_runs(createdAt)`);
|
||||
this.db.exec(`CREATE INDEX IF NOT EXISTS idxResearchRunsUpdatedAt ON research_runs(updatedAt)`);
|
||||
this.db.exec(`CREATE INDEX IF NOT EXISTS idxResearchRunsProjectTriggerStatus ON research_runs(projectId, trigger, status)`);
|
||||
|
||||
this.db.exec(`
|
||||
CREATE TABLE IF NOT EXISTS research_exports (
|
||||
@@ -2293,6 +2336,64 @@ export class Database {
|
||||
this.applyMigration(59, () => {
|
||||
this.db.exec(`CREATE INDEX IF NOT EXISTS idxTasksColumn ON tasks("column")`);
|
||||
this.db.exec(`CREATE INDEX IF NOT EXISTS idxTasksUpdatedAt ON tasks(updatedAt DESC)`);
|
||||
|
||||
if (this.hasTable("research_runs")) {
|
||||
this.addColumnIfMissing("research_runs", "projectId", "TEXT");
|
||||
this.addColumnIfMissing("research_runs", "trigger", "TEXT");
|
||||
this.addColumnIfMissing("research_runs", "lifecycle", "TEXT");
|
||||
this.db.exec(`CREATE INDEX IF NOT EXISTS idxResearchRunsProjectTriggerStatus ON research_runs(projectId, trigger, status)`);
|
||||
}
|
||||
|
||||
this.db.exec(`
|
||||
CREATE TABLE IF NOT EXISTS research_run_events (
|
||||
id TEXT PRIMARY KEY,
|
||||
runId TEXT NOT NULL,
|
||||
seq INTEGER NOT NULL,
|
||||
type TEXT NOT NULL,
|
||||
message TEXT NOT NULL,
|
||||
status TEXT,
|
||||
classification TEXT,
|
||||
metadata TEXT,
|
||||
createdAt TEXT NOT NULL,
|
||||
FOREIGN KEY (runId) REFERENCES research_runs(id) ON DELETE CASCADE
|
||||
)
|
||||
`);
|
||||
if (this.hasTable("research_run_events")) {
|
||||
this.addColumnIfMissing("research_run_events", "seq", "INTEGER NOT NULL DEFAULT 0");
|
||||
}
|
||||
this.db.exec(`CREATE INDEX IF NOT EXISTS idxResearchRunEventsRunIdSeq ON research_run_events(runId, seq)`);
|
||||
|
||||
if (this.hasTable("project_insight_runs")) {
|
||||
this.addColumnIfMissing("project_insight_runs", "lifecycle", "TEXT");
|
||||
this.addColumnIfMissing("project_insight_runs", "cancelledAt", "TEXT");
|
||||
this.db.exec(`CREATE INDEX IF NOT EXISTS idxInsightRunsProjectTriggerStatus ON project_insight_runs(projectId, trigger, status)`);
|
||||
}
|
||||
|
||||
this.db.exec(`
|
||||
CREATE TABLE IF NOT EXISTS project_insight_run_events (
|
||||
id TEXT PRIMARY KEY,
|
||||
runId TEXT NOT NULL,
|
||||
seq INTEGER NOT NULL,
|
||||
type TEXT NOT NULL,
|
||||
message TEXT NOT NULL,
|
||||
status TEXT,
|
||||
classification TEXT,
|
||||
metadata TEXT,
|
||||
createdAt TEXT NOT NULL,
|
||||
FOREIGN KEY (runId) REFERENCES project_insight_runs(id) ON DELETE CASCADE
|
||||
)
|
||||
`);
|
||||
if (this.hasTable("project_insight_run_events")) {
|
||||
this.addColumnIfMissing("project_insight_run_events", "seq", "INTEGER NOT NULL DEFAULT 0");
|
||||
}
|
||||
this.db.exec(`CREATE INDEX IF NOT EXISTS idxInsightRunEventsRunIdSeq ON project_insight_run_events(runId, seq)`);
|
||||
});
|
||||
}
|
||||
|
||||
if (version < 60) {
|
||||
this.applyMigration(60, () => {
|
||||
this.addColumnIfMissing("tasks", "pausedByAgentId", "TEXT");
|
||||
this.db.exec(`CREATE INDEX IF NOT EXISTS idxTasksPausedByAgentId ON tasks(pausedByAgentId)`);
|
||||
});
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user