forked from M-Labs/artiq
1
0
Fork 0

Use logger formatting

This commit is contained in:
Charles Baynham 2020-05-26 10:50:03 +01:00 committed by Sébastien Bourdeauducq
parent 8858ba8095
commit 692c466838
1 changed files with 3 additions and 3 deletions

View File

@ -183,16 +183,16 @@ class AppletsCCBDock(applets.AppletsDock):
else: else:
spec = {"ty": "code", "code": code, "command": command} spec = {"ty": "code", "code": code, "command": command}
if applet is None: if applet is None:
logger.debug('Applet {} does not exist: creating'.format(name)) logger.debug("Applet %s does not exist: creating", name)
applet = self.new(name=name, spec=spec, parent=parent) applet = self.new(name=name, spec=spec, parent=parent)
else: else:
if spec != self.get_spec(applet): if spec != self.get_spec(applet):
logger.debug('Applet {} already exists: updating existing spec'.format(name)) logger.debug("Applet %s already exists: updating existing spec", name)
self.set_spec(applet, spec) self.set_spec(applet, spec)
if applet.applet_dock: if applet.applet_dock:
asyncio.ensure_future(applet.applet_dock.restart()) asyncio.ensure_future(applet.applet_dock.restart())
else: else:
logger.debug('Applet {} already exists and no update required'.format(name)) logger.debug("Applet %s already exists and no update required", name)
if ccbp == "enable": if ccbp == "enable":
applet.setCheckState(0, QtCore.Qt.Checked) applet.setCheckState(0, QtCore.Qt.Checked)