diff --git a/pymeasure/experiment/experiment.py b/pymeasure/experiment/experiment.py index cb121773dd..0fe37a4177 100644 --- a/pymeasure/experiment/experiment.py +++ b/pymeasure/experiment/experiment.py @@ -34,7 +34,7 @@ from pymeasure.log import setup_logging, console_log from pymeasure.experiment import Results, Worker -log = logging.getLogger() +log = logging.getLogger(__name__) log.addHandler(logging.NullHandler()) try: diff --git a/pymeasure/experiment/procedure.py b/pymeasure/experiment/procedure.py index 75888950cb..91dc89f0bc 100644 --- a/pymeasure/experiment/procedure.py +++ b/pymeasure/experiment/procedure.py @@ -33,7 +33,7 @@ from .parameters import Parameter, Measurable, Metadata from pymeasure.units import ureg -log = logging.getLogger() +log = logging.getLogger(__name__) log.addHandler(logging.NullHandler()) diff --git a/pymeasure/experiment/workers.py b/pymeasure/experiment/workers.py index 7271dd9017..fa2a91a80c 100644 --- a/pymeasure/experiment/workers.py +++ b/pymeasure/experiment/workers.py @@ -73,7 +73,7 @@ def __init__(self, results, log_queue=None, log_level=logging.INFO, port=None): self.log_level = log_level global log - log = logging.getLogger() + log = logging.getLogger(__name__) log.setLevel(self.log_level) # log.handlers = [] # Remove all other handlers # log.addHandler(TopicQueueHandler(self.monitor_queue))