Mike Statkus <[EMAIL PROTECTED]> added the comment: Example of UnicodeWriter.writerow(self,row) presented in Python 2.5 Manual at section 9.1.5 (Examples on CSV module of standard library) does not correctly process rows containing not only strings, but also int type values, raising an attribute error. 1st line of code in UnicodeWriter.writerow: self.writer.writerow([s.encode("utf-8") for s in row]) tries to call .encode() method for s, that might be an int, not a string. A simple workaround is: self.writer.writerow([unicode(s).encode("utf-8") for s in row])
---------- nosy: +mstatkus _______________________________________ Python tracker <[EMAIL PROTECTED]> <http://bugs.python.org/issue1606092> _______________________________________ _______________________________________________ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com