feat(generator): add build worker with retries and placeholder fallback

Co-Authored-By: Claude Opus 4.7 <noreply@anthropic.com>
This commit is contained in:
shay
2026-04-17 16:53:17 -04:00
co-authored by Claude Opus 4.7
parent 97ad1c2b39
commit 07221a1329
3 changed files with 144 additions and 1 deletions
+2 -1
View File
@@ -230,7 +230,8 @@ def claim_next_job() -> Optional[dict]:
c.execute("UPDATE jobs SET status='running', updated_at=?, attempts=attempts+1 WHERE id=?",
(now, row["id"]))
c.commit()
return {"id": row["id"], "username": row["username"], "kind": row["kind"], "status": "running"}
return {"id": row["id"], "username": row["username"], "kind": row["kind"],
"status": "running", "attempts": row["attempts"] + 1}
def complete_job(job_id: int) -> None: