Skip to content

Commit

Permalink
fix exception
Browse files Browse the repository at this point in the history
  • Loading branch information
ut112 committed Oct 25, 2017
1 parent 4579469 commit fe05fa8
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion health_check/contrib/rmq/backends.py
Original file line number Diff line number Diff line change
Expand Up @@ -12,5 +12,5 @@ def check_status(self):
logger = logging.getLogger(__name__)
try:
pika.BlockingConnection(pika.ConnectionParameters(settings.HEALTH_CHECK_CONF['rmq_host']))
except Exception, e:
except Exception as e:
raise ServiceUnavailable("Connection Error")
2 changes: 1 addition & 1 deletion health_check/contrib/sqs/backends.py
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,6 @@ def check_status(self):
aws_access_key_id=settings.HEALTH_CHECK_CONF['aws_access_key_id']
)
q = sqs.get_queue_by_name(QueueName=settings.HEALTH_CHECK_CONF['sqs_queue_name'])
except Exception, e:
except Exception as e:
ServiceUnavailable("connection error")

0 comments on commit fe05fa8

Please sign in to comment.