Skip to content

Commit

Permalink
Py3 fix: decode response before json.loads
Browse files Browse the repository at this point in the history
  • Loading branch information
nemesifier committed May 2, 2015
1 parent a011aa8 commit 8712255
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion netdiff/parsers/base.py
Original file line number Diff line number Diff line change
Expand Up @@ -54,7 +54,7 @@ def _to_python(self, data):
data = open(data).read()
# if it looks like a URL
elif data.startswith('http'):
data = requests.get(data, verify=False).content
data = requests.get(data, verify=False).content.decode()
# assuming is JSON
try:
return json.loads(data)
Expand Down

0 comments on commit 8712255

Please sign in to comment.