diff options
Diffstat (limited to 'qolab')
-rw-r--r-- | qolab/tsdb/__init__.py | 7 |
1 files changed, 5 insertions, 2 deletions
diff --git a/qolab/tsdb/__init__.py b/qolab/tsdb/__init__.py index 7f7ecc0..a985534 100644 --- a/qolab/tsdb/__init__.py +++ b/qolab/tsdb/__init__.py @@ -38,7 +38,10 @@ def tsdb_append_metric_for_class_setter_or_getter(tsdb_logger=None): action = f.__name__[0:3] var_name = f.__name__[3:] val = None - device_type=cls.config['Device type'] + if cls.config['DeviceNickname'] is not None: + device_type=cls.config['DeviceNickname'] + else: + device_type=cls.config['Device type'] if action == 'get': """ getter """ val = f(*args, **kwds) @@ -86,7 +89,7 @@ if __name__ == '__main__': """ get D variable """ return self.d - dev = InstWithLog(tsdb_ingester=tsdb_ingester) + dev = InstWithLog(tsdb_ingester=tsdb_ingester, device_nickname='tester') dev.getD() dev.setD(3) |