diff --git a/scripts/ci-code-queue-read-perf.ts b/scripts/ci-code-queue-read-perf.ts index c7642a89..80fe6b14 100644 --- a/scripts/ci-code-queue-read-perf.ts +++ b/scripts/ci-code-queue-read-perf.ts @@ -111,6 +111,7 @@ async function candidateTasks(url: string): Promise { ...tasks.filter((task) => terminalStatus(task.status) && ((task.stepCount ?? 0) === 0 || task.stepCount === null)), ...tasks.filter((task) => terminalStatus(task.status)), ...tasks.filter((task) => !terminalStatus(task.status) && task.status !== "queued" && task.status !== "running" && task.status !== "judging"), + ...tasks, ]; const seen = new Set(); return ordered.filter((task) => { @@ -148,7 +149,7 @@ async function traceSeq(url: string, taskId: string, timeoutMs: number): Promise async function traceTarget(url: string): Promise<{ taskId: string; skippedTaskIds: string[]; selection: JsonValue }> { const tasks = await candidateTasks(url); - if (tasks.length === 0) throw new Error("Code Queue CI perf could not find a terminal task id in the production PostgreSQL task table"); + if (tasks.length === 0) throw new Error("Code Queue CI perf could not find a task id in the production PostgreSQL task table"); const target = tasks[0]; if (target === undefined) throw new Error("Code Queue CI perf could not select a task from the production PostgreSQL task table"); return { taskId: target.id, skippedTaskIds: tasks.slice(1).map((task) => task.id), selection: target as unknown as JsonValue };