era added the comment:
At least the following existing domain names are rejected by the current
implementation, apparently because they are not IDNA2003-compatible.
XN----NNC9BXA1KSA.COM
XN--14-CUD4D3A.COM
XN--YGB4AR5HPA.COM
XN---14-00E9E9A.COM
XN--MGB2DAM4BK.COM
XN--6-ZHCPPA1B7A.COM
XN--3-YMCCH8IVAY.COM
XN--3-YMCLXLE2A3F.COM
XN--4-ZHCJXA0E.COM
XN--014-QQEUW.COM
XN--118-Y2EK60DC2ZB.COM
As a workaround, in the code where I needed to process these, I used a fallback
to string[4:].decode('punycode'); this was in a code path where I had already
lowercased the string and established that string[0:4] == 'xn--'.
As a partial remedy, supporting a relaxed interpretation of the spec somehow
would be useful; see also (tangentially) issue #12263.
----------
nosy: +era
_______________________________________
Python tracker <[email protected]>
<http://bugs.python.org/issue17305>
_______________________________________
_______________________________________________
Python-bugs-list mailing list
Unsubscribe:
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com