diff options
author | Andrew Leeming <andrew.leeming@codethink.co.uk> | 2016-08-23 12:47:31 +0100 |
---|---|---|
committer | Andrew Leeming <andrew.leeming@codethink.co.uk> | 2016-08-23 13:19:39 +0100 |
commit | 6ed7422cf5ee58df8c4f928a5ff34c1046eb42c7 (patch) | |
tree | 7a6c2092f474ff0c5b9f1e01066147de28961079 | |
parent | be1851a372cb54c129c08f97c6e5f7dda372bb47 (diff) | |
download | sandboxlib-leeming/root-logger-fix.tar.gz |
Fixed a minor bug with root loggerleeming/root-logger-fix
If the root logger is used instead of a named 'sandboxlib' logger. This causes potential issues for 3rd party tools using this library
-rw-r--r-- | sandboxlib/__init__.py | 2 | ||||
-rw-r--r-- | sandboxlib/load/appc.py | 1 | ||||
-rw-r--r-- | sandboxlib/utils.py | 3 |
3 files changed, 3 insertions, 3 deletions
diff --git a/sandboxlib/__init__.py b/sandboxlib/__init__.py index 3571eb6..beaf7b2 100644 --- a/sandboxlib/__init__.py +++ b/sandboxlib/__init__.py @@ -161,7 +161,7 @@ def executor_for_platform(): if 'SANDBOXLIB_BACKEND' in os.environ: backend_name = os.environ['SANDBOXLIB_BACKEND'] - logging.info("Got %s from SANDBOXLIB_BACKEND variable.", backend_name) + log.info("Got %s from SANDBOXLIB_BACKEND variable.", backend_name) try: backend = get_executor(backend_name) except KeyError: diff --git a/sandboxlib/load/appc.py b/sandboxlib/load/appc.py index 7cbafc1..fd1dd4c 100644 --- a/sandboxlib/load/appc.py +++ b/sandboxlib/load/appc.py @@ -18,7 +18,6 @@ import contextlib import json -import logging import os import shutil import tarfile diff --git a/sandboxlib/utils.py b/sandboxlib/utils.py index b3ec867..e9b049a 100644 --- a/sandboxlib/utils.py +++ b/sandboxlib/utils.py @@ -42,7 +42,8 @@ def find_program(program_name): argv = ['which', program_name] program_path = subprocess.check_output(argv).strip() except subprocess.CalledProcessError as e: - logging.debug("Error searching for %s: %s", program_name, e) + log = logging.getLogger('sandboxlib') + log.debug("Error searching for %s: %s", program_name, e) program_path = None if program_path is None: |