Re: __unicode__() works, unicode() blows up. (Never mind!)

2012-11-04 Thread Terry Reedy
On 11/4/2012 8:41 AM, Roy Smith wrote: In article , Roy Smith wrote: print u.__unicode__() None print unicode(u) Traceback (most recent call last): File "", line 1, in TypeError: coercing to Unicode: need string or buffer, NoneType found What's going on here? I thought (http://docs

Re: __unicode__() works, unicode() blows up. (Never mind!)

2012-11-04 Thread Aahz
In article , Roy Smith wrote: >In article , > Roy Smith wrote: >> >> >>> print u.__unicode__() >> None >> >> >>> print unicode(u) >> Traceback (most recent call last): >> File "", line 1, in >> TypeError: coercing to Unicode: need string or buffer, NoneType found >> >> What's going on here?

Re: __unicode__() works, unicode() blows up. (Never mind!)

2012-11-04 Thread Roy Smith
In article , Roy Smith wrote: > >>> print u.__unicode__() > None > > >>> print unicode(u) > Traceback (most recent call last): > File "", line 1, in > TypeError: coercing to Unicode: need string or buffer, NoneType found > > What's going on here? I thought > (http://docs.python.org/2/libr