mirror of
https://github.com/tiqi-group/pydase.git
synced 2025-04-22 17:10:02 +02:00
updates logging message formatting
This commit is contained in:
parent
d057710b60
commit
f38df58842
@ -86,8 +86,8 @@ class StateManager:
|
|||||||
json.dump(self.cache, f, indent=4)
|
json.dump(self.cache, f, indent=4)
|
||||||
else:
|
else:
|
||||||
logger.error(
|
logger.error(
|
||||||
f"Class {self.__class__.__name__} was not initialised with a filename. "
|
"State manager was not initialised with a filename. Skipping "
|
||||||
'Skipping "write_to_file"...'
|
"'save_state'..."
|
||||||
)
|
)
|
||||||
|
|
||||||
def load_state(self) -> None:
|
def load_state(self) -> None:
|
||||||
@ -121,7 +121,7 @@ class StateManager:
|
|||||||
)
|
)
|
||||||
if class_attr_is_read_only:
|
if class_attr_is_read_only:
|
||||||
logger.debug(
|
logger.debug(
|
||||||
f'Attribute "{path}" is read-only. Ignoring value from JSON '
|
f"Attribute {path!r} is read-only. Ignoring value from JSON "
|
||||||
"file..."
|
"file..."
|
||||||
)
|
)
|
||||||
continue
|
continue
|
||||||
@ -136,8 +136,8 @@ class StateManager:
|
|||||||
self.service.update_DataService_attribute(parts[:-1], attr_name, value)
|
self.service.update_DataService_attribute(parts[:-1], attr_name, value)
|
||||||
else:
|
else:
|
||||||
logger.info(
|
logger.info(
|
||||||
f'Attribute type of "{path}" changed from "{value_type}" to '
|
f"Attribute type of {path!r} changed from {value_type!r} to "
|
||||||
f'"{class_value_type}". Ignoring value from JSON file...'
|
f"{class_value_type!r}. Ignoring value from JSON file..."
|
||||||
)
|
)
|
||||||
|
|
||||||
def _get_state_dict_from_JSON_file(self) -> dict[str, Any]:
|
def _get_state_dict_from_JSON_file(self) -> dict[str, Any]:
|
||||||
|
Loading…
x
Reference in New Issue
Block a user