feat(workbench): keep only actionable notifications

This commit is contained in:
2026-09-24 15:18:18 +08:00
parent e374b5b3cb
commit db092b0f5e
8 changed files with 192 additions and 38 deletions
+10
View File
@@ -357,6 +357,7 @@ async def test_complete_without_same_generation_artifacts_fails_run_explicitly()
assert repository.run["failure_code"] == "ARTIFACT_INCOMPLETE"
assert completed.lifecycle_status == "failed"
assert completed.active_run is None
assert [item["kind"] for item in repository.notifications] == ["task_failed"]
@pytest.mark.anyio
@@ -451,6 +452,9 @@ async def test_plan_only_keeps_lease_until_same_generation_report_closes_run():
)
assert completed.status == "waiting_human"
assert completed.agent_lease_expires_at is None
assert [item["kind"] for item in repository.notifications] == [
"human_input_required"
]
@pytest.mark.anyio
@@ -521,6 +525,9 @@ async def test_action_proposal_keeps_running_lease_until_plan_and_report_close_r
)
assert closed.status == "waiting_human"
assert closed.actions[0].action_id == action.action_id
assert [item["kind"] for item in repository.notifications] == [
"action_approval_pending"
]
@pytest.mark.anyio
@@ -786,6 +793,9 @@ async def test_interrupted_submit_replays_unknown_without_dispatching_twice():
assert dispatcher.calls == 1
assert replay.execution_status == "unknown"
assert replay.execution_request_id is not None
assert [item["kind"] for item in repository.notifications] == [
"external_coordination_failed"
]
@pytest.mark.anyio