Skip to content

Commit 8712255

Browse files
committed
Py3 fix: decode response before json.loads
1 parent a011aa8 commit 8712255

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

netdiff/parsers/base.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -54,7 +54,7 @@ def _to_python(self, data):
5454
data = open(data).read()
5555
# if it looks like a URL
5656
elif data.startswith('http'):
57-
data = requests.get(data, verify=False).content
57+
data = requests.get(data, verify=False).content.decode()
5858
# assuming is JSON
5959
try:
6060
return json.loads(data)

0 commit comments

Comments
 (0)