Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 3 additions & 2 deletions apps/api/src/tools/task-board/review-sweeper.ts
Original file line number Diff line number Diff line change
Expand Up @@ -336,9 +336,10 @@ export class TaskBoardReviewSweeper {
const item = await this.taskBoard.getById(id, organizationId);
// Re-read before spending a run: a human may have moved or reassigned
// the card between the scan and here, and their move wins.
const lanes = await boardLanesForDb(this.db, organizationId);
if (
!item ||
item.status !== "in_progress" ||
item.status !== lanes.progress ||
item.assigneeId !== SUPER_AGENT_ASSIGNEE_ID
) {
continue;
Expand Down Expand Up @@ -413,7 +414,7 @@ export class TaskBoardReviewSweeper {
try {
const lanes = await boardLanesForDb(this.db, organizationId);
const item = await this.taskBoard.getById(id, organizationId);
if (!item || item.status !== "in_progress") return;
if (!item || item.status !== lanes.progress) return;
const returned = await this.taskBoard.returnToTodoAfterFailure(
id,
organizationId,
Expand Down
Loading