URL: https://github.com/freeipa/freeipa/pull/3466 Author: Tiboris Title: #3466: [Backport][ipa-4-8] ipapython/admintool.py: use SERVER_NOT_CONFIGURED Action: opened
PR body: """ This PR was opened automatically because PR #3458 was pushed to master and backport to ipa-4-8 is required. """ To pull the PR as Git branch: git remote add ghfreeipa https://github.com/freeipa/freeipa git fetch ghfreeipa pull/3466/head:pr3466 git checkout pr3466
From 32155eff5ddcdac2d2e0704008945f207c98cfdc Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Fran=C3=A7ois=20Cami?= <fc...@redhat.com> Date: Mon, 29 Jul 2019 11:22:09 +0200 Subject: [PATCH] ipapython/admintool.py: use SERVER_NOT_CONFIGURED MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Commit 9182917280a5c2590fa677729db54b38a9ac4d1f introduced SUCCESS, SERVER_INSTALL_ERROR and SERVER_NOT_CONFIGURED to deal with cases when server is not configured. Actually use SERVER_NOT_CONFIGURED in log_failure instead of 2. Related-to: https://pagure.io/freeipa/issue/6843 Signed-off-by: François Cami <fc...@redhat.com> --- ipapython/admintool.py | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/ipapython/admintool.py b/ipapython/admintool.py index 5aa8cf1e93..ededb28bfd 100644 --- a/ipapython/admintool.py +++ b/ipapython/admintool.py @@ -317,9 +317,7 @@ def log_failure(self, error_message, return_value, exception, backtrace): # ipa-server-install. return message = "The %s command failed." % self.command_name - if self.log_file_initialized and return_value != 2: - # magic value because this is common between server and client - # but imports are not straigthforward + if self.log_file_initialized and return_value != SERVER_NOT_CONFIGURED: message += " See %s for more information" % self.log_file_name logger.error('%s', message)
_______________________________________________ FreeIPA-devel mailing list -- freeipa-devel@lists.fedorahosted.org To unsubscribe send an email to freeipa-devel-le...@lists.fedorahosted.org Fedora Code of Conduct: https://docs.fedoraproject.org/en-US/project/code-of-conduct/ List Guidelines: https://fedoraproject.org/wiki/Mailing_list_guidelines List Archives: https://lists.fedorahosted.org/archives/list/freeipa-devel@lists.fedorahosted.org