1
0
mirror of https://github.com/kakwa/ldapcherry synced 2024-11-22 09:24:21 +01:00

adding more debug traces in case of a faulty backend

This commit is contained in:
kakwa 2015-07-25 22:02:53 +02:00
parent 4f83667e50
commit f6b1128274

View File

@ -188,11 +188,12 @@ class LdapCherry(object):
# Loading the backend module # Loading the backend module
try: try:
module = params['module'] module = params['module']
except: except Exception as e:
raise MissingParameter('backends', backend + '.module') raise MissingParameter('backends', backend + '.module')
try: try:
bc = __import__(module, globals(), locals(), ['Backend'], -1) bc = __import__(module, globals(), locals(), ['Backend'], -1)
except: except Exception as e:
self._handle_exception(e)
raise BackendModuleLoadingFail(module) raise BackendModuleLoadingFail(module)
try: try:
attrslist = self.attributes.get_backend_attributes(backend) attrslist = self.attributes.get_backend_attributes(backend)
@ -206,7 +207,8 @@ class LdapCherry(object):
) )
except MissingParameter as e: except MissingParameter as e:
raise e raise e
except: except Exception as e:
self._handle_exception(e)
raise BackendModuleInitFail(module) raise BackendModuleInitFail(module)
def _init_ppolicy(self, config): def _init_ppolicy(self, config):