pkgs/clan: Remove select debug prints

This commit is contained in:
a-kenji
2025-02-04 14:05:00 +07:00
committed by kenji
parent 6242416fc4
commit 11468c42af

View File

@@ -192,7 +192,6 @@ class FlakeCacheEntry:
self.value[sel].is_cached(selectors[1:]) for sel in self.value
)
# TODO: check if we already have all the keys anyway?
print("not cached because self.selector is not all")
return False
if (
isinstance(selector, set)
@@ -200,15 +199,12 @@ class FlakeCacheEntry:
and isinstance(self.value, dict)
):
if not selector.issubset(self.selector):
print("not cached because selector is not subset of self.selector")
return False
return all(self.value[sel].is_cached(selectors[1:]) for sel in selector)
if isinstance(selector, str | int) and isinstance(self.value, dict):
if selector in self.value:
return self.value[selector].is_cached(selectors[1:])
print("not cached because selector is not in self.value")
return False
print("not cached because of unknown reason")
return False
def select(self, selectors: list[Selector]) -> Any: