From 4532de368ac29c85be1539e9554ca52e6286cc09 Mon Sep 17 00:00:00 2001 From: William Wernert Date: Wed, 26 Jan 2022 16:04:45 -0500 Subject: [PATCH] Fix error message printing in so-rule --- salt/common/tools/sbin/so-rule | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/salt/common/tools/sbin/so-rule b/salt/common/tools/sbin/so-rule index 71f17dc53..603a6cae9 100755 --- a/salt/common/tools/sbin/so-rule +++ b/salt/common/tools/sbin/so-rule @@ -80,7 +80,10 @@ def find_minion_pillar() -> str: print_err('Could not find manager-type pillar (eval, standalone, manager, managersearch, import). Are you running this script on the manager?') sys.exit(3) elif len(result) > 1: - res_str = ', '.join(f'\"{result}\"') + res_arr = [] + for r in result: + res_arr.append(f'\"{r}\"') + res_str = ', '.join(res_arr) print_err('(This should not happen, the system is in an error state if you see this message.)\n') print_err('More than one manager-type pillar exists, minion id\'s listed below:') print_err(f' {res_str}')