Minor tweaks about code quality.

This commit is contained in:
Romain Dorgueil
2018-07-16 10:00:28 +02:00
parent d9f2fd3009
commit 6a1203602f
9 changed files with 9 additions and 15 deletions

View File

@ -29,7 +29,7 @@ class ExecutorStrategy(Strategy):
with self.create_executor() as executor:
try:
context.start(self.get_starter(executor, futures))
except:
except Exception:
logger.critical('Exception caught while starting execution context.', exc_info=sys.exc_info())
while context.alive:
@ -53,14 +53,14 @@ class ExecutorStrategy(Strategy):
try:
with node:
node.loop()
except:
except Exception:
logging.getLogger(__name__).critical(
'Critical error in threadpool node starter.', exc_info=sys.exc_info()
)
try:
futures.append(executor.submit(_runner))
except:
except Exception:
logging.getLogger(__name__).critical('futures.append', exc_info=sys.exc_info())
return starter