diff --git a/README.md b/README.md index 0e6bc8da38db6532273b7bc4d9de8d45e06f1e8f..32bc142a9dcecc96ece2a47a1ea99dc6f5979af1 100644 --- a/README.md +++ b/README.md @@ -62,9 +62,9 @@ This will create "log namespaces" which allow you to filter out messages from va ## Attributions Free software used: * Qt via either: - * [PyQt5](https://riverbankcomputing.com/software/pyqt/intro) - GPLv3 License, Copyright (c) 2018 Riverbank Computing Limited <info@riverbankcomputing.com> + * [PyQt5](https://riverbankcomputing.com/software/pyqt/intro) - GPLv3 License, Copyright (c) 2019 Riverbank Computing Limited <info@riverbankcomputing.com> * [PySide2](https://wiki.qt.io/PySide2) - LGPLv3 License, Copyright (C) 2015 The Qt Company Ltd (http://www.qt.io/licensing/) -* [QtPy](https://github.com/spyder-ide/qtpy) - MIT License, Copyright © 2009–2018 The Spyder Development Team +* [QtPy](https://github.com/spyder-ide/qtpy) - MIT License, Copyright © 2009–2019 The Spyder Development Team * [ion-icons](https://github.com/ionic-team/ionicons) - MIT License, Copyright (c) 2015-present Ionic (http://ionic.io/) And thanks to [logview](https://pythonhosted.org/logview/) by Vinay Sajip for UI inspiration. diff --git a/cutelog/config.py b/cutelog/config.py index 770bf2c6a5f3371e3d5e42bb1da8e376b0f94757..2af282dcd22948fb50aadd6929589db28b3cdab7 100644 --- a/cutelog/config.py +++ b/cutelog/config.py @@ -185,8 +185,15 @@ class Config(QObject): if option.type == bool: value = str(value).lower() # needed because QSettings stores bools as strings value = True if value == "true" or value is True else False + elif option.type == int and value is None: + value = 0 # workaround for bug PYSIDE-820 else: - value = option.type(value) + try: + value = option.type(value) + except Exception: + self.log.warn('Could not parse value "{}" for option "{}", falling back to the ' + 'default value "{}"'.format(value, option.name, option.default)) + value = option.default options[option.name] = value self.qsettings.endGroup() return options diff --git a/cutelog/listener.py b/cutelog/listener.py index db2bb4cbe8c0562bad492b8f4f8ffe76721debdb..9d50c4370d371617b81428e5fe54bacb14c02744 100644 --- a/cutelog/listener.py +++ b/cutelog/listener.py @@ -204,6 +204,8 @@ class LogConnection(QThread): self.deserialize = self.serializers[value] else: self.log.error('Serialization format "{}" is not supported'.format(value)) + else: + self.log.error('No such command "{}"'.format(cmd)) class BenchmarkConnection(LogConnection): diff --git a/cutelog/logger_table_header.py b/cutelog/logger_table_header.py index 444516c5d638966bd7deae516fb8328225e10611..5110ef699679d665218e16174853eaf840e8ed57 100644 --- a/cutelog/logger_table_header.py +++ b/cutelog/logger_table_header.py @@ -100,7 +100,7 @@ class LoggerTableHeader(QObject): def regen_visible(self): self.visible_columns = [c for c in self.columns if c.visible] self.visible_names = set([c.name for c in self.visible_columns]) | SPECIAL_COLUMNS - print(self.visible_names) + # print(self.visible_names) for i, column in enumerate(self.visible_columns): self.header_view.resizeSection(i, column.width) diff --git a/setup.py b/setup.py index 179c59ffff6eb30c88df1ec0e8cba6a28db935d4..131121b2a276021999758a85f27dded0e8d30fb1 100644 --- a/setup.py +++ b/setup.py @@ -5,7 +5,7 @@ from setuptools import setup from setuptools.command.install import install -VERSION = '2.0.2' +VERSION = '2.0.3' def build_qt_resources():