commit 6c44b7e9e9174559fb5268801ce1fc79db38c35d
Author: Ralph Bean <rbean(a)redhat.com>
Date: Sat May 9 18:49:11 2015 -0400
Raise an exception when unable to decode JSON.
pkgdb2client/__init__.py | 2 +-
1 files changed, 1 insertions(+), 1 deletions(-)
---
diff --git a/pkgdb2client/__init__.py b/pkgdb2client/__init__.py
index 0254288..6b2ed8d 100644
--- a/pkgdb2client/__init__.py
+++ b/pkgdb2client/__init__.py
@@ -348,8 +348,8 @@ class PkgDB(object):
try:
output = response.json()
except Exception, err:
- LOG.debug('Error while decoding the JSON: {0}'.format(err))
LOG.debug(response.text)
+ raise PkgDBException('Error while decoding JSON: {0}'.format(err))
if response.status_code != 200:
LOG.debug('full output: {0}'.format(output))
Show replies by date