Skip to content

The open-source app everyone uses to manage agents at work

Merge pull request #2643 from chrisschwer/fix/stale-execution-lock-lifecycle

Dotta943b851a5ed8
diff --cc server/src/services/issues.ts
index 21c340f4c4,0ee8456378..bb40be79d3
--- a/server/src/services/issues.ts
+++ b/server/src/services/issues.ts
@@@ -1638,9 -1301,13 +1642,13 @@@ export function issueService(db: Db)
(issueData.assigneeUserId !== undefined && issueData.assigneeUserId !== existing.assigneeUserId)
) {
patch.checkoutRunId = null;
+ // Fix B: clear execution lock on reassignment, matching checkoutRunId clear
+ patch.executionRunId = null;
+ patch.executionAgentNameKey = null;
+ patch.executionLockedAt = null;
}
- return db.transaction(async (tx) => {
+ const runUpdate = async (tx: any) => {
const defaultCompanyGoal = await getDefaultCompanyGoal(tx, existing.companyId);
const [currentProjectGoalId, nextProjectGoalId] = await Promise.all([
getProjectDefaultGoalId(tx, existing.companyId, existing.projectId),