From b30b25216bf1db86dd3a59f0a745423c67e8c939 Mon Sep 17 00:00:00 2001 From: norohind <60548839+norohind@users.noreply.github.com> Date: Mon, 16 Aug 2021 15:24:01 +0300 Subject: [PATCH] companion.py: change raising exception when pretending CAPI down --- companion.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/companion.py b/companion.py index eadfb1d9..f9ea3b37 100644 --- a/companion.py +++ b/companion.py @@ -567,7 +567,7 @@ class Session(object): try: logger.trace_if('capi.query', 'Trying...') if conf_module.capi_pretend_down: - raise ServerError(f'Pretending CAPI is down for {endpoint} endpoint') + raise ServerConnectionError(f'Pretending CAPI down: {endpoint}') r = self.session.get(self.server + endpoint, timeout=timeout) # type: ignore