[issue3763] Python 3.0 beta 2 : json and urllib not working together?
Swaroop
report at bugs.python.org
Wed Sep 3 11:17:42 CEST 2008
Swaroop <swaroopch at gmail.com> added the comment:
Adding full traceback:
$ python yahoo_search.py
Traceback (most recent call last):
File "yahoo_search.py", line 35, in <module>
for result in search(query)['Result']:
File "yahoo_search.py", line 28, in search
result = json.load(urllib.request.urlopen(url))
File "C:\Python30\lib\json\__init__.py", line 267, in load
parse_constant=parse_constant, **kw)
File "C:\Python30\lib\json\__init__.py", line 307, in loads
return _default_decoder.decode(s)
File "C:\Python30\lib\json\decoder.py", line 322, in decode
raise ValueError(errmsg("Extra data", s, end, len(s)))
File "C:\Python30\lib\json\decoder.py", line 30, in errmsg
lineno, colno = linecol(doc, pos)
File "C:\Python30\lib\json\decoder.py", line 21, in linecol
lineno = doc.count('\n', 0, pos) + 1
TypeError: expected an object with the buffer interface
_______________________________________
Python tracker <report at bugs.python.org>
<http://bugs.python.org/issue3763>
_______________________________________
More information about the Python-bugs-list
mailing list