Skip to content

Commit

Permalink
Fix range error in engine.py
Browse files Browse the repository at this point in the history
And a trailing whitespace
  • Loading branch information
MGlauer authored Jun 20, 2019
1 parent c92487e commit 13a56f1
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions oedialect/engine.py
Original file line number Diff line number Diff line change
Expand Up @@ -189,7 +189,7 @@ def post(self, suffix, query, cursor_id=None, requires_connection_id=False):

if 'info_cache' in query:
del query['info_cache']

data = {'query': query}

if requires_connection_id or cursor_id:
Expand Down Expand Up @@ -235,7 +235,7 @@ def post(self, suffix, query, cursor_id=None, requires_connection_id=False):
def process_returntype(response, content=None):
if content is None:
content = {}
if 400 < response.status_code < 500:
if 400 <= response.status_code < 500:
raise ConnectionException('HTTP %d (%s)'%(response.status_code,response.reason))
elif 500 <= response.status_code < 600:
raise ConnectionException('Server side error: ' + content.get('reason', 'No reason returned'))
Expand Down

0 comments on commit 13a56f1

Please sign in to comment.