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 vstinner
Recipients marco.sulla, vstinner
Date 2016-03-14.10:35:51
SpamBayes Score -1.0
Marked as misclassified Yes
Message-id <1457951751.76.0.846872215369.issue26555@psf.upfronthosting.co.za>
In-reply-to
Content
> I would that the format minilanguage will convert bytes to string properly.

Sorry, nope, Python 3 doesn't guess the encoding of byte strings anymore. You have to decode manually. Example:

"Hello {}".format(b"World".decode('ascii'))

Or format to bytes:

b"Hello {}".format(b"World")

It's not a bug. It's a feature.
History
Date User Action Args
2016-03-14 10:35:51vstinnersetrecipients: + vstinner, marco.sulla
2016-03-14 10:35:51vstinnersetmessageid: <1457951751.76.0.846872215369.issue26555@psf.upfronthosting.co.za>
2016-03-14 10:35:51vstinnerlinkissue26555 messages
2016-03-14 10:35:51vstinnercreate