From 789c3b869adf5bbd1379d3054c00c3dfc7d22c4c Mon Sep 17 00:00:00 2001 From: blitzmann Date: Sun, 6 May 2018 13:04:02 -0400 Subject: [PATCH] Add new Exception type --- service/esi.py | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/service/esi.py b/service/esi.py index c2fe03b47..02890a2a3 100644 --- a/service/esi.py +++ b/service/esi.py @@ -35,6 +35,9 @@ if not os.path.exists(cache_path): file_cache = FileCache(cache_path) +class EsiException(Exception): + pass + class Servers(Enum): TQ = 0 SISI = 1 @@ -170,7 +173,7 @@ class Esi(object): def check_response(self, resp): if resp.status != 200: - raise Exception(resp.status) + raise EsiException(resp.status) return resp @staticmethod