Skip to content
This repository has been archived by the owner on Jul 16, 2024. It is now read-only.

Commit

Permalink
Merge pull request #100 from CameronJHall/master
Browse files Browse the repository at this point in the history
Changed HTTPError to RequestException in Notifier
  • Loading branch information
James Bell authored May 7, 2019
2 parents e10671f + c94ed98 commit 7ebf3df
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 5 deletions.
3 changes: 2 additions & 1 deletion setup.py
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@

setup(
name='tgt_grease',
version='2.6.0',
version='2.6.1',
license="MIT",
description='Modern distributed automation engine built with love by Target',
long_description="""
Expand Down Expand Up @@ -34,6 +34,7 @@
test_suite='nose.collector',
tests_require=['nose', 'nose-cover3', 'mock'],
install_requires=[
'urllib3==1.24.3',
'psycopg2-binary',
'requests',
'pymongo',
Expand Down
6 changes: 2 additions & 4 deletions tgt_grease/core/Notifier.py
Original file line number Diff line number Diff line change
@@ -1,6 +1,5 @@
from tgt_grease.core import Configuration
from logging import DEBUG, INFO, WARNING, ERROR, CRITICAL
from urllib3.exceptions import HTTPError
import requests
import json

Expand Down Expand Up @@ -147,7 +146,7 @@ def send_hipchat_message(self, message, level, color=None):
return True
else:
return False
except HTTPError:
except requests.exceptions.RequestException:
return False

def send_slack_message(self, message):
Expand All @@ -170,6 +169,5 @@ def send_slack_message(self, message):
headers={'Content-Type': 'application/json'}
)
return True
except HTTPError:
except requests.exceptions.RequestException:
return False

0 comments on commit 7ebf3df

Please sign in to comment.