Merge pull request 'clan-cli: Make select query reproducible, by sorting select keys' (#5625) from Qubasa/clan-core:repro_select into main

Reviewed-on: https://git.clan.lol/clan/clan-core/pulls/5625
This commit is contained in:
Luis Hebendanz
2025-10-22 13:04:01 +00:00
2 changed files with 2 additions and 2 deletions

View File

@@ -163,7 +163,7 @@ class InventoryStore:
return sanitize(filtered, self._allowed_path_transforms, [])
def get_readonly_raw(self, keys: set[str]) -> Inventory:
attrs = "{" + ",".join(keys) + "}"
attrs = "{" + ",".join(sorted(keys)) + "}"
return self._flake.select(f"clanInternals.inventoryClass.inventory.{attrs}")
def _get_persisted(self) -> InventorySnapshot:

View File

@@ -237,7 +237,7 @@ def get_service_readmes(
if input_name is None:
query_param = "staticModules"
service_queries = "{" + ",".join(service_names) + "}"
service_queries = "{" + ",".join(sorted(service_names)) + "}"
query = (
f"clanInternals.inventoryClass.{query_param}.{service_queries}.manifest.readme"