From bbc2186e17d039e0f6a3e4a8d3eabcfaec4670f7 Mon Sep 17 00:00:00 2001 From: Bob Fahr <20520336+bfahr@users.noreply.github.com> Date: Wed, 22 Jun 2022 23:50:15 -0500 Subject: [PATCH] Update canonical_facts to load needed components (#3448) * get_canonical_facts needs to work for legacy archives that do not include meta_data Signed-off-by: Bob Fahr <20520336+bfahr@users.noreply.github.com> --- insights/util/canonical_facts.py | 5 +---- 1 file changed, 1 insertion(+), 4 deletions(-) diff --git a/insights/util/canonical_facts.py b/insights/util/canonical_facts.py index 934b0a6eb7..6bf7dab6eb 100644 --- a/insights/util/canonical_facts.py +++ b/insights/util/canonical_facts.py @@ -135,7 +135,7 @@ def canonical_facts( def get_canonical_facts(path=None): - load_components("insights.specs.default") + load_components("insights.specs.default", "insights.specs.insights_archive") set_enabled(canonical_facts, True) set_enabled(SubscriptionManagerID, True) @@ -149,7 +149,4 @@ def get_canonical_facts(path=None): if __name__ == "__main__": import json - # Load both default and archive to support host and archive collection - load_components("insights.specs.default", "insights.specs.insights_archive") - print(json.dumps(get_canonical_facts()))