fix: preserve CP host siblings during stale cleanup

This commit is contained in:
2026-05-08 02:06:04 +08:00
parent 2df832dec0
commit 08d518c2ed
2 changed files with 71 additions and 1 deletions

View File

@@ -1104,7 +1104,11 @@ class HiRadixCache(RadixCache):
if not self._node_backuped(x):
if len(x.children) == 0:
parent = self._remove_host_leaf(x)
if parent.evicted and self._node_backuped(parent):
if (
len(parent.children) == 0
and parent.evicted
and self._node_backuped(parent)
):
new_priority = self.eviction_strategy.get_priority(parent)
heapq.heappush(eviction_heap, (new_priority, parent))
continue