X-Git-Url: https://git.llucax.com/software/pymin.git/blobdiff_plain/12b7d86229346c68e653a51d1e6598a5973901ba..HEAD:/pymin/service/__init__.py diff --git a/pymin/service/__init__.py b/pymin/service/__init__.py index 1828fb4..9de5b96 100644 --- a/pymin/service/__init__.py +++ b/pymin/service/__init__.py @@ -1,17 +1,22 @@ # vim: set encoding=utf-8 et sw=4 sts=4 : import imp +import logging ; log = logging.getLogger('pymin.service') class LoadError(ImportError): pass def load_service(name, search_paths): + log.debug('load_service(%s, %r)', name, search_paths) try: (fp, path, desc) = imp.find_module(name, search_paths) except ImportError: raise LoadError('module "%s" not found' % name) + log.debug('load_service() -> find_module() returned %r', (fp, path, desc)) try: + m = imp.load_module(name, fp, path, desc) + log.debug('load_service() -> loaded module %r', m) return imp.load_module(name, fp, path, desc) finally: if fp: