This issue tracker has been migrated to GitHub, and is currently read-only.
For more information, see the GitHub FAQs in the Python's Developer Guide.

Author amaury.forgeotdarc
Recipients amaury.forgeotdarc, georg.brandl, r.david.murray
Date 2009-06-26.10:56:25
SpamBayes Score 4.8575905e-05
Marked as misclassified No
Message-id <1246013788.2.0.143113245857.issue6304@psf.upfronthosting.co.za>
In-reply-to
Content
The problem here is not the bytes object: it is correctly coerced to a
string. 

The problem is the binary stream, which cannot accept strings.
We could maybe detect common errors and add a check at the beginning of
the print() function? something like
    if isinstance(file, (BufferedWriter, RawIOBase)):
        raise ValueError("file should be a text stream")
History
Date User Action Args
2009-06-26 10:56:28amaury.forgeotdarcsetrecipients: + amaury.forgeotdarc, georg.brandl, r.david.murray
2009-06-26 10:56:28amaury.forgeotdarcsetmessageid: <1246013788.2.0.143113245857.issue6304@psf.upfronthosting.co.za>
2009-06-26 10:56:26amaury.forgeotdarclinkissue6304 messages
2009-06-26 10:56:25amaury.forgeotdarccreate