fix(nodes): snapshot scanner cache before iterating on executor thread

Node code reads cache.raw_data while MetadataSyncService may mutate it
from a background thread; iterate over a list() snapshot to avoid a
possible 'list changed size during iteration' RuntimeError.
This commit is contained in:
Will Miao
2026-09-14 11:05:12 +08:00
parent 326df32933
commit db38ad80e6
4 changed files with 6 additions and 6 deletions
+1 -1
View File
@@ -156,7 +156,7 @@ def _find_missing_loras(names: list[str]) -> list[str]:
lookup = {}
basename_candidates = {}
for item in cache.raw_data:
for item in list(cache.raw_data):
file_path = item.get("file_path")
if not file_path:
continue