From 9a1acf792db9f9d1988be62368e6e7df92cd8d7f Mon Sep 17 00:00:00 2001 From: yumoqing Date: Thu, 3 Sep 2026 19:16:33 +0800 Subject: [PATCH] =?UTF-8?q?feat:=20D2=E6=A0=B8=E9=AA=8C=E9=80=9A=E8=BF=87?= =?UTF-8?q?=E5=90=8E=E8=87=AA=E5=8A=A8=E6=81=A2=E5=A4=8Dverify=5Ffailed?= =?UTF-8?q?=E4=BB=BB=E5=8A=A1=E4=B8=BAapproved+=E8=87=AA=E5=8A=A8=E5=85=B3?= =?UTF-8?q?=E9=97=ADoutput=5Fverify=E5=BE=85=E5=8A=9E?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- pipeline_bidding/bid_flow.py | 14 ++++++++++++++ 1 file changed, 14 insertions(+) diff --git a/pipeline_bidding/bid_flow.py b/pipeline_bidding/bid_flow.py index 40fe9b0..c40347a 100644 --- a/pipeline_bidding/bid_flow.py +++ b/pipeline_bidding/bid_flow.py @@ -777,6 +777,20 @@ async def reconcile_project(sor, project_id, project_name=""): assignee_role="owner.superuser") await sor.sqlExe("COMMIT", {}) acts.append("escalated: 产出落库核验不通过(%d 个任务标 verify_failed),抛人工" % len(verify_bad)) + else: + # 2026-09-03:核验全通过且有待处理的 output_verify → 自动关闭(问题已解决); + # 之前标 verify_failed 的人工修正任务,落库后恢复 approved(状态与事实一致) + await sor.sqlExe( + "UPDATE pipeline_tasks SET state='approved', updated_at=NOW() " + "WHERE tenant_id=${p}$ AND role=${r}$ AND state='verify_failed'", + {"p": project_id, "r": R_ANALYST}) + ht = await find_human_task(sor, project_id, "output_verify", status="pending") + if ht: + await sor.sqlExe( + "UPDATE pipeline_human_tasks SET status='done', updated_at=NOW() " + "WHERE id=${h}$", {"h": ht.get("id")}) + acts.append("auto-closed: output_verify 待办(落库核验已通过)") + await sor.sqlExe("COMMIT", {}) if created_w or created_r: return acts