From 356d246aa083486cf1b6d70440ba13da376ea249 Mon Sep 17 00:00:00 2001 From: Haiwei Xu Date: Wed, 4 Sep 2013 18:19:30 +0900 Subject: [PATCH] Fix the code miss to show the correct error messages In keystone/common/ldap/core.py I found the code like below: 86 raise ValueError(_( 87 'Invalid LDAP TLS certs option: %(option). ' 88 'Choose one of: %(options)s') % { The code "%(option)" in line 87 should be fixed to "%(option)s" to show the correct error messages when the exception happens. This patch fixes this error. Fixes bug #1220601 Change-Id: I87328080facd4d9b1349a677c00a93d118993538 --- keystone/common/ldap/core.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/keystone/common/ldap/core.py b/keystone/common/ldap/core.py index 9e8e7ab264..f1c368a980 100644 --- a/keystone/common/ldap/core.py +++ b/keystone/common/ldap/core.py @@ -84,7 +84,7 @@ def parse_tls_cert(opt): return LDAP_TLS_CERTS[opt] except KeyError: raise ValueError(_( - 'Invalid LDAP TLS certs option: %(option). ' + 'Invalid LDAP TLS certs option: %(option)s. ' 'Choose one of: %(options)s') % { 'option': opt, 'options': ', '.join(LDAP_TLS_CERTS.keys())})