From 95d4c5c03c6df79828bccf87315d380a4c9594c3 Mon Sep 17 00:00:00 2001 From: jfuller Date: Tue, 5 Dec 2023 09:18:11 +0100 Subject: [PATCH] Minor: add count back and set --search-provides as default --- griffon/commands/queries.py | 2 +- griffon/services/core_queries.py | 3 +-- 2 files changed, 2 insertions(+), 3 deletions(-) diff --git a/griffon/commands/queries.py b/griffon/commands/queries.py index cf258bc..adeb18d 100644 --- a/griffon/commands/queries.py +++ b/griffon/commands/queries.py @@ -383,7 +383,7 @@ def get_product_contain_component( and not search_provides and not search_upstreams ): - ctx.params["search_latest"] = True + ctx.params["search_provides"] = True params = copy.deepcopy(ctx.params) params.pop("verbose") diff --git a/griffon/services/core_queries.py b/griffon/services/core_queries.py index a92e6cc..d9762c7 100644 --- a/griffon/services/core_queries.py +++ b/griffon/services/core_queries.py @@ -362,8 +362,7 @@ def execute(self, status=None) -> List[Dict[str, Any]]: search_provides_params["active_streams"] = "True" search_provides_params["latest_components_by_streams"] = "True" status.update("searching latest provided child component(s).") - # latest_components_cnt = self.corgi_session.components.count(**search_provides_params) - latest_components_cnt = 0 + latest_components_cnt = self.corgi_session.components.count(**search_provides_params) status.update(f"found {latest_components_cnt} latest provides component(s).") latest_components = self.corgi_session.components.retrieve_list_iterator_async( **search_provides_params