From 407c9e57c8f6c94fa6fc4d7c2062c38957c8f0f8 Mon Sep 17 00:00:00 2001 From: chrys Date: Tue, 30 Aug 2016 23:51:17 +0200 Subject: [PATCH] try except --- src/fenrir-package/fenrir.py | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/src/fenrir-package/fenrir.py b/src/fenrir-package/fenrir.py index afaf91ba..18bfbda0 100755 --- a/src/fenrir-package/fenrir.py +++ b/src/fenrir-package/fenrir.py @@ -29,7 +29,10 @@ class fenrir(): def handleProcess(self): self.environment, timeout = self.environment['runtime']['inputManager'].proceedInputEvents(self.environment) - self.environment = self.environment['runtime']['screenDriver'].analyzeScreen(self.environment) + try: + self.environment = self.environment['runtime']['screenDriver'].analyzeScreen(self.environment) + except Exception as e: + self.environment['runtime']['debug'].writeDebugOut(self.environment, str(e)+' error happy loop at'+str(time.time()),debug.debugLevel.ERROR) if not self.environment['input']['keyForeward']: self.environment = self.environment['runtime']['commandManager'].getCommandForShortcut(self.environment) if not timeout: