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 ned.deily
Recipients ablack, ned.deily
Date 2018-03-02.21:32:44
SpamBayes Score -1.0
Marked as misclassified Yes
Message-id <1520026364.18.0.467229070634.issue32958@psf.upfronthosting.co.za>
In-reply-to
Content
Thanks for the report.  The behavior you see can be further isolated to socket.gethostbyname:

>>> import socket
>>> h = "0123456789012345678901234567890123456789012345678901234567890123.example.com"
>>> socket.gethostbyname(h)
Traceback (most recent call last):
  File "/usr/lib/python3.6/encodings/idna.py", line 165, in encode
    raise UnicodeError("label empty or too long")
UnicodeError: label empty or too long

The above exception was the direct cause of the following exception:

Traceback (most recent call last):
  File "<stdin>", line 1, in <module>
UnicodeError: encoding with 'idna' codec failed (UnicodeError: label empty or too long)

Other socket module calls accepting host names fail similarly, such as getaddrinfo.
History
Date User Action Args
2018-03-02 21:32:44ned.deilysetrecipients: + ned.deily, ablack
2018-03-02 21:32:44ned.deilysetmessageid: <1520026364.18.0.467229070634.issue32958@psf.upfronthosting.co.za>
2018-03-02 21:32:44ned.deilylinkissue32958 messages
2018-03-02 21:32:44ned.deilycreate