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 steven.daprano
Recipients Nicholas Willhite, ezio.melotti, steven.daprano, vstinner
Date 2021-06-04.05:11:15
SpamBayes Score -1.0
Marked as misclassified Yes
Message-id <1622783475.41.0.201747116301.issue44308@roundup.psfhosted.org>
In-reply-to
Content
I think you have missed something important here:

    >>> data = b'foo\bar'
    >>> len(data)
    6
    >>> print(data)
    b'foo\x08ar'


If you want bytes including a backslash followed by a b, you need to use raw bytes rb'foo\bar' or escape the backslash.

Also Python 3.8 is in feature-freeze so the earliest this new feature could be added to the language is now 3.11.
History
Date User Action Args
2021-06-04 05:11:15steven.dapranosetrecipients: + steven.daprano, vstinner, ezio.melotti, Nicholas Willhite
2021-06-04 05:11:15steven.dapranosetmessageid: <1622783475.41.0.201747116301.issue44308@roundup.psfhosted.org>
2021-06-04 05:11:15steven.dapranolinkissue44308 messages
2021-06-04 05:11:15steven.dapranocreate