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 matpi
Recipients ezio.melotti, malin, matpi, mrabarnett
Date 2020-06-16.12:37:23
SpamBayes Score -1.0
Marked as misclassified Yes
Message-id <1592311044.06.0.273919075593.issue40980@roundup.psfhosted.org>
In-reply-to
Content
But Δ has no latin-1 representation. So Δ currently cannot be used as a group name in bytes regex, although it is a valid Python identifier. So that's a bug.

I mean, if you insist of having group names as strings even for bytes regexes, then it is not reasonable to prevent them from going _in_.

b"(??<\xce\x94>)" is a valid utf-8-encoded bytestring, why wouldn't you accept it as a valid re pattern?

IMHO, either

- group names from byte regexes should be returned as bytes
- or any utf-8-encoded representation of a valid Python identifier should be accepted as a group name of a bytes regex pattern.
History
Date User Action Args
2020-06-16 12:37:24matpisetrecipients: + matpi, ezio.melotti, mrabarnett, malin
2020-06-16 12:37:24matpisetmessageid: <1592311044.06.0.273919075593.issue40980@roundup.psfhosted.org>
2020-06-16 12:37:24matpilinkissue40980 messages
2020-06-16 12:37:23matpicreate