[issue10976] json.loads() raises TypeError on bytes object

2014-04-04 Thread Hanxue Lee

Hanxue Lee added the comment:

This seems to be an issue (bug?) for Python 3.3 When calling json.loads() with 
a byte array, this is the error

json.loads(response.data, 'latin-1')

TypeError: can't use a string pattern on a bytes-like object


When I decode the byte array to string

json.loads(response.data.decode(), 'latin-1')

I get this error

TypeError: bytes or integer address expected instead of str instance

--
nosy: +Hanxue.Lee

___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue10976
___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue13936] RFE: change bool(datetime.time(0, 0, 0)) to evaluate as True

2014-03-06 Thread Hanxue Lee

Changes by Hanxue Lee leehan...@gmail.com:


--
nosy: +Hanxue.Lee

___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue13936
___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com