aboutsummaryrefslogtreecommitdiffstats
path: root/iceci/decorator/exception_decor.py
diff options
context:
space:
mode:
authorEdan Binshtok <eb578m@intl.att.com>2017-11-19 11:50:50 +0200
committerEdan Binshtok <eb578m@intl.att.com>2017-11-19 11:51:04 +0200
commit71891b3040605103397ffa7fb349215eced3a2c3 (patch)
tree22dda04edd1b8ee0d0de2a6a260d6d60e42cba25 /iceci/decorator/exception_decor.py
parent433a8256e31f755f5e236491bbe39d3db24d6d6d (diff)
Pep8 another fixes
Add more fixes to pep8 Issue-ID: VVP-25 Change-Id: Icc3bd3977ced2b537c858a9801e04a6bf6d1db05 Signed-off-by: Edan Binshtok <eb578m@intl.att.com>
Diffstat (limited to 'iceci/decorator/exception_decor.py')
-rw-r--r--iceci/decorator/exception_decor.py9
1 files changed, 4 insertions, 5 deletions
diff --git a/iceci/decorator/exception_decor.py b/iceci/decorator/exception_decor.py
index 467f2ce..2bbced7 100644
--- a/iceci/decorator/exception_decor.py
+++ b/iceci/decorator/exception_decor.py
@@ -1,5 +1,5 @@
-
-# ============LICENSE_START==========================================
+
+# ============LICENSE_START==========================================
# org.onap.vvp/test-engine
# ===================================================================
# Copyright © 2017 AT&T Intellectual Property. All rights reserved.
@@ -36,7 +36,6 @@
# ============LICENSE_END============================================
#
# ECOMP is a trademark and service mark of AT&T Intellectual Property.
-import logging
import traceback
from services.logging_service import LoggingServiceFactory
@@ -48,7 +47,7 @@ logger = LoggingServiceFactory.get_logger()
def exception():
"""
- A decorator that wraps the passed in function and logs
+ A decorator that wraps the passed in function and logs
exceptions should one occur
@param logger: The logging object
@@ -59,7 +58,7 @@ def exception():
def wrapper(*args, **kwargs):
try:
return func(*args, **kwargs)
- except:
+ except BaseException:
err = "There was an exception in %s" % func.__name__
logger.error(err)
session.errorCounter += 1