Flows and dashboards are created by POST under an issued or superuser-pinned id; PUT only updates; deleted flows leave a tombstone with their key; the controller stores by id and runs by key, hooks live under /hooks/<flow id>; a key with state or queued work behind it is refused until cleared

This commit is contained in:
2026-11-02 17:41:23 +01:00
parent fae85f5ecb
commit 08a6376836
63 changed files with 2832 additions and 936 deletions
@@ -96,10 +96,10 @@ def test_a_flow_that_cannot_run_makes_the_summary_degraded(
controller = client.app.state.flow_controller
before = controller.issues
before_flows = controller.store.list_flows
before_flows = controller.store.key_index
# The looping flow has to be one the store lists, otherwise "running"
# counts nothing either way and the assertion below proves nothing.
controller.store.list_flows = lambda: ["looping"]
controller.store.key_index = lambda: {"looping": "f_looping"}
controller.issues = [
ValidationIssue(
code="cycle",
@@ -119,7 +119,7 @@ def test_a_flow_that_cannot_run_makes_the_summary_degraded(
body = client.get(f"{PREFIX}/summary", headers=superuser_token_headers).json()
finally:
controller.issues = before
controller.store.list_flows = before_flows
controller.store.key_index = before_flows
assert body["status"] == "degraded"
assert body["flows"]["invalid"] == 1