From: Randolph Brown <rgb@pa...> - 2003-12-14 06:41:37
Just a note that test_email.py fails for Jython because email is checking
for instances of UnicodeType and treating them differently from those of
./email/Charset.py:10: return isinstance(s, UnicodeType)
./email/Header.py:278: elif isinstance(s, UnicodeType):
There is, of course, no such difference in Jython.
Interestingly, these uses seem to be supporting a "robust" programming
style -- allowing the user of the email package to pass in a unicode
string, but declare that it is, in fact, encoded by some codec. The
package notes that it can't really be encoded because it's unicode and
doesn't decode it.
A quick scan over the rest of the Python 2.2 standard library shows no
other test of unicode that doesn't also test for string.