diff options
| author | David Pursehouse <david.pursehouse@sonymobile.com> | 2015-06-24 17:20:30 +0900 |
|---|---|---|
| committer | David Pursehouse <david.pursehouse@sonymobile.com> | 2015-06-24 17:26:42 +0900 |
| commit | aa9567b181693e1b2c6a3debf5072071f4aeaea3 (patch) | |
| tree | 5841eb233cea9f4756f3d0d0ec925fdc9bbacbb4 /pygerrit/rest | |
| parent | c2f5438808bec10e9e18c75ce81b4f31c7d00a21 (diff) | |
| download | pygerrit-aa9567b181693e1b2c6a3debf5072071f4aeaea3.tar.gz | |
Add debug log of response content
Change-Id: If57c2f4443405a546d7aee796c8381c053e1b301
Diffstat (limited to 'pygerrit/rest')
| -rw-r--r-- | pygerrit/rest/__init__.py | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/pygerrit/rest/__init__.py b/pygerrit/rest/__init__.py index baf2dc1..b51f41a 100644 --- a/pygerrit/rest/__init__.py +++ b/pygerrit/rest/__init__.py @@ -41,8 +41,9 @@ def _decode_response(response): requests.HTTPError if the response contains an HTTP error status code. """ - response.raise_for_status() content = response.content + logging.debug(content[:512]) + response.raise_for_status() if content.startswith(GERRIT_MAGIC_JSON_PREFIX): content = content[len(GERRIT_MAGIC_JSON_PREFIX):] try: |
