From 5dc31c1e13e7c863e0f2305571173ee23a9b355f Mon Sep 17 00:00:00 2001 From: damocles Date: Mon, 1 Jun 2026 16:50:40 +0200 Subject: [PATCH] fix(948): make topology_sort pub --- hive-c0re/src/auto_update.rs | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/hive-c0re/src/auto_update.rs b/hive-c0re/src/auto_update.rs index 012e2863..601d5417 100644 --- a/hive-c0re/src/auto_update.rs +++ b/hive-c0re/src/auto_update.rs @@ -209,7 +209,7 @@ pub async fn ensure_manager(coord: &Arc) -> Result<()> { /// Sort `names` in-place so parents precede their children in the topology. /// Uses BFS from root agents (depth 0). Agents absent from `topo` sort last, /// alphabetically within their tier. Stable within each depth tier. -fn topology_sort(names: &mut Vec, topo: &std::collections::BTreeMap>) { +pub fn topology_sort(names: &mut Vec, topo: &std::collections::BTreeMap>) { use std::collections::{HashMap, VecDeque}; // Build depth map using owned clones so the borrow on `names` is released // before the sort_by mutable borrow. @@ -300,3 +300,4 @@ pub async fn run(coord: Arc) -> Result<()> { coord.emit_rebuild_queue_snapshot(); Ok(()) } +