From 8de8beb5f9c0ba79cd6c5c307e91e1af5f3da92e Mon Sep 17 00:00:00 2001 From: Schrolli Date: Mon, 18 May 2015 15:32:06 +0200 Subject: [PATCH] little changes --- plugin_test/boswatch.log | 56 ++++++++++++++++-------- plugin_test/plugin_test.py | 2 +- plugin_test/plugins/template/__init__.py | 2 +- 3 files changed, 40 insertions(+), 20 deletions(-) diff --git a/plugin_test/boswatch.log b/plugin_test/boswatch.log index 1239a8d..0564611 100644 --- a/plugin_test/boswatch.log +++ b/plugin_test/boswatch.log @@ -1,29 +1,49 @@ -18.05.2015 03:26:47 - INFO: Alarm! -18.05.2015 03:26:47 - DEBUG: Loading plugin template -18.05.2015 03:26:47 - DEBUG: Throw Template Plugin -18.05.2015 03:26:47 - INFO: ZVEI: 12345 wurde auf 80000000 empfangen! -18.05.2015 03:26:47 - DEBUG: try 5/0 -18.05.2015 03:26:47 - ERROR: Error in Template Plugin +18.05.2015 03:30:59 - INFO: Alarm! +18.05.2015 03:30:59 - DEBUG: Loading plugin template +18.05.2015 03:30:59 - DEBUG: Throw Template Plugin +18.05.2015 03:30:59 - INFO: ZVEI: 12345 wurde auf 80000000 empfangen! +18.05.2015 03:30:59 - DEBUG: try 5/0 +18.05.2015 03:30:59 - ERROR: Error in Template Plugin Traceback (most recent call last): File "./plugins\template\__init__.py", line 8, in run test = 5/0 ZeroDivisionError: division by zero -18.05.2015 03:26:48 - INFO: Alarm! -18.05.2015 03:26:48 - DEBUG: Loading plugin template -18.05.2015 03:26:48 - DEBUG: Throw Template Plugin -18.05.2015 03:26:48 - INFO: ZVEI: 12345 wurde auf 80000000 empfangen! -18.05.2015 03:26:48 - DEBUG: try 5/0 -18.05.2015 03:26:48 - ERROR: Error in Template Plugin +18.05.2015 03:31:00 - INFO: Alarm! +18.05.2015 03:31:00 - DEBUG: Loading plugin template +18.05.2015 03:31:00 - DEBUG: Throw Template Plugin +18.05.2015 03:31:00 - INFO: ZVEI: 12345 wurde auf 80000000 empfangen! +18.05.2015 03:31:00 - DEBUG: try 5/0 +18.05.2015 03:31:00 - ERROR: Error in Template Plugin Traceback (most recent call last): File "./plugins\template\__init__.py", line 8, in run test = 5/0 ZeroDivisionError: division by zero -18.05.2015 03:26:49 - INFO: Alarm! -18.05.2015 03:26:49 - DEBUG: Loading plugin template -18.05.2015 03:26:49 - DEBUG: Throw Template Plugin -18.05.2015 03:26:49 - INFO: ZVEI: 12345 wurde auf 80000000 empfangen! -18.05.2015 03:26:49 - DEBUG: try 5/0 -18.05.2015 03:26:49 - ERROR: Error in Template Plugin +18.05.2015 03:31:01 - INFO: Alarm! +18.05.2015 03:31:01 - DEBUG: Loading plugin template +18.05.2015 03:31:01 - DEBUG: Throw Template Plugin +18.05.2015 03:31:01 - INFO: ZVEI: 12345 wurde auf 80000000 empfangen! +18.05.2015 03:31:01 - DEBUG: try 5/0 +18.05.2015 03:31:01 - ERROR: Error in Template Plugin +Traceback (most recent call last): + File "./plugins\template\__init__.py", line 8, in run + test = 5/0 +ZeroDivisionError: division by zero +18.05.2015 03:31:02 - INFO: Alarm! +18.05.2015 03:31:02 - DEBUG: Loading plugin template +18.05.2015 03:31:02 - DEBUG: Throw Template Plugin +18.05.2015 03:31:02 - INFO: ZVEI: 12345 wurde auf 80000000 empfangen! +18.05.2015 03:31:02 - DEBUG: try 5/0 +18.05.2015 03:31:02 - ERROR: Error in Template Plugin +Traceback (most recent call last): + File "./plugins\template\__init__.py", line 8, in run + test = 5/0 +ZeroDivisionError: division by zero +18.05.2015 03:31:03 - INFO: Alarm! +18.05.2015 03:31:03 - DEBUG: Loading plugin template +18.05.2015 03:31:03 - DEBUG: Throw Template Plugin +18.05.2015 03:31:03 - INFO: ZVEI: 12345 wurde auf 80000000 empfangen! +18.05.2015 03:31:03 - DEBUG: try 5/0 +18.05.2015 03:31:03 - ERROR: Error in Template Plugin Traceback (most recent call last): File "./plugins\template\__init__.py", line 8, in run test = 5/0 diff --git a/plugin_test/plugin_test.py b/plugin_test/plugin_test.py index 01b86be..b85c5c2 100644 --- a/plugin_test/plugin_test.py +++ b/plugin_test/plugin_test.py @@ -41,6 +41,6 @@ while True: time.sleep(1) logging.info("Alarm!") for i in pluginloader.getPlugins(): - logging.debug("Loading plugin " + i["name"]) + logging.debug("Load Plugin: " + i["name"]) plugin = pluginloader.loadPlugin(i) plugin.run("zvei","80000000",data) \ No newline at end of file diff --git a/plugin_test/plugins/template/__init__.py b/plugin_test/plugins/template/__init__.py index 36938b1..bd86c59 100644 --- a/plugin_test/plugins/template/__init__.py +++ b/plugin_test/plugins/template/__init__.py @@ -1,7 +1,7 @@ import logging def run(typ,freq,data): - logging.debug("Throw Template Plugin") + logging.debug("Strat Plugin: template") try: logging.info("ZVEI: %s wurde auf %s empfangen!", data["zvei"],freq) logging.debug("try 5/0")