Éric Araujo added the comment: I don’t understand that the first message says.
If one wants to call the write method of a file object opened in binary mode, one needs to pass bytes, as the doc surely explains. The same error that is seen here with ints would be seen with any other objects. A more practical way is to use print (with its file, sep and end parameters) which will do the conversion for you. ---------- nosy: +eric.araujo _______________________________________ Python tracker <rep...@bugs.python.org> <http://bugs.python.org/issue17859> _______________________________________ _______________________________________________ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com