From ee53aa195ad78d03e5b252ee8f9f51f35bc75df3 Mon Sep 17 00:00:00 2001 From: "Eugeniy E. Mikhailov" Date: Sun, 19 Dec 2021 15:19:15 -0500 Subject: gui use logging --- qolab/gui/web.py | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) (limited to 'qolab/gui') diff --git a/qolab/gui/web.py b/qolab/gui/web.py index 6013e14..4c23ea4 100644 --- a/qolab/gui/web.py +++ b/qolab/gui/web.py @@ -2,6 +2,9 @@ import justpy as jp import asyncio import matplotlib.pyplot as plt +import logging +logger = logging.getLogger('qolab.gui.web') + button_classes = 'bg-blue-500 hover:bg-blue-700 text-white font-bold py-2 px-4 rounded-full' label_div_classes = 'py-2 px-4' checkbox_classed = label_div_classes @@ -170,7 +173,7 @@ class QOLSaveControls(jp.Div): return if self.component_with_data is None: return - print(f'saving to {fname}') + logger.debug(f'saving to {fname}') self.component_with_data.save(fname) async def _next_file(self, msg): @@ -180,6 +183,7 @@ class QOLSaveControls(jp.Div): def next_file(self): if self.getNextDataFile is not None: fname = self.getNextDataFile() + logger.info(f'Data will be saved to {fname}') self.file_name.setValue( fname ) if self.component_with_data is not None: self.component_with_data.clear_last_saved_pos() -- cgit v1.2.3