From 793a47f2fd5d99d085d0703256351c99e42c42e7 Mon Sep 17 00:00:00 2001 From: David Zingg Date: Wed, 20 Nov 2019 21:47:14 +0100 Subject: [PATCH] #6 UI Updates senden und anzeigen --- octoprint_mystromswitch/__init__.py | 12 +----------- 1 file changed, 1 insertion(+), 11 deletions(-) diff --git a/octoprint_mystromswitch/__init__.py b/octoprint_mystromswitch/__init__.py index 854655b..83d6840 100644 --- a/octoprint_mystromswitch/__init__.py +++ b/octoprint_mystromswitch/__init__.py @@ -55,13 +55,11 @@ class MyStromSwitchPlugin(octoprint.plugin.SettingsPlugin, self._timer.start() def _timer_task(self): - self._logger.debug("timer_task") if self.ip is not None: - self._logger.debug("send Request") try: request = requests.get( 'http://{}/report'.format(self.ip), timeout=1) - self._logger.debug(request.json()) + self._logger.info(request.json()) # self._plugin_manager.send_plugin_message(self._identifier, # request.json()) except (requests.exceptions.ConnectionError, ValueError): @@ -76,14 +74,6 @@ class MyStromSwitchPlugin(octoprint.plugin.SettingsPlugin, def on_shutdown(self): self._logger.info("Hello World!") - def on_settings_load(self): - self._logger.info("on_settings_load") - self.initialize() - - def on_settings_initialized(self): - self._logger.info("on_settings_initialized") - self.initialize() - def on_settings_migrate(self, target, current): pass