From 12ce7d2e4e27dd209ad9a3027b36ff3b4d6f0c10 Mon Sep 17 00:00:00 2001 From: Martin Krizek Date: Wed, 5 Apr 2023 18:18:04 +0200 Subject: [PATCH] dnf5: fix module/pkg names in the failed respawn msg (#80402) --- changelogs/fragments/dnf5-fix-interpreter-fail-msg.yml | 2 ++ lib/ansible/modules/dnf5.py | 4 ++-- 2 files changed, 4 insertions(+), 2 deletions(-) create mode 100644 changelogs/fragments/dnf5-fix-interpreter-fail-msg.yml diff --git a/changelogs/fragments/dnf5-fix-interpreter-fail-msg.yml b/changelogs/fragments/dnf5-fix-interpreter-fail-msg.yml new file mode 100644 index 00000000000..d6db8c39500 --- /dev/null +++ b/changelogs/fragments/dnf5-fix-interpreter-fail-msg.yml @@ -0,0 +1,2 @@ +bugfixes: + - dnf5 - fix module and package names in the message following failed module respawn attempt diff --git a/lib/ansible/modules/dnf5.py b/lib/ansible/modules/dnf5.py index e25c79142d4..6efa2a47fd7 100644 --- a/lib/ansible/modules/dnf5.py +++ b/lib/ansible/modules/dnf5.py @@ -445,8 +445,8 @@ class Dnf5Module(YumDnf): # done all we can do, something is just broken (auto-install isn't useful anymore with respawn, so it was removed) self.module.fail_json( - msg="Could not import the dnf python module using {0} ({1}). " - "Please install `python3-dnf` or `python2-dnf` package or ensure you have specified the " + msg="Could not import the libdnf5 python module using {0} ({1}). " + "Please install python3-libdnf5 package or ensure you have specified the " "correct ansible_python_interpreter. (attempted {2})".format( sys.executable, sys.version.replace("\n", ""), system_interpreters ),