mirror of
https://github.com/hansjone/netx.git
synced 2026-10-09 03:10:46 +08:00
fix(collect): stabilize start flow and default collapse create panel
Avoid false running-state conflicts when starting draft jobs, block overlapping NE runs across jobs, and default the create panel to collapsed for cleaner task-first operation. Co-authored-by: Cursor <cursoragent@cursor.com>
This commit is contained in:
parent
52f1b63b18
commit
d512679425
6 changed files with 87 additions and 11 deletions
|
|
@ -129,7 +129,7 @@ def _claim_run(job_id: str, run_id: str) -> bool:
|
|||
if job_status != "running":
|
||||
return False
|
||||
if run_status == "running":
|
||||
return True
|
||||
return False
|
||||
if run_status != "pending":
|
||||
return False
|
||||
run.status = "running"
|
||||
|
|
@ -149,7 +149,7 @@ def _run_single(job_id: str, run_id: str, commands: list[str]) -> None:
|
|||
try:
|
||||
run = db.get(NeCollectionRun, run_id)
|
||||
st = str(run.status or "") if run else ""
|
||||
if st in ("cancelled", "success", "fail"):
|
||||
if st in ("cancelled", "success", "fail", "running"):
|
||||
sync_job_progress(db, job_id)
|
||||
finalize_collection_job(db, job_id)
|
||||
return
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue