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 iritkatriel
Recipients Joel.Lovinger, ZackerySpytz, iritkatriel, jackdied, r.david.murray
Date 2020-11-30.10:07:00
SpamBayes Score -1.0
Marked as misclassified Yes
Message-id <1606730820.76.0.710206730855.issue14556@roundup.psfhosted.org>
In-reply-to
Content
This has been fixed by now:

Running Release|x64 interpreter...
Python 3.10.0a2+ (heads/bpo-42482:920f808f50, Nov 29 2020, 23:02:47) [MSC v.1916 64 bit (AMD64)] on win32
Type "help", "copyright", "credits" or "license" for more information.
>>> from telnetlib import Telnet
>>> import time
>>> tn = Telnet("scn.org", 23)
>>> time.sleep(5) # short wait for data to be available
>>> tn.expect(['.{16}'], 0)
Traceback (most recent call last):
  File "<stdin>", line 1, in <module>
  File "C:\Users\User\src\cpython\lib\telnetlib.py", line 622, in expect
    m = list[i].search(self.cookedq)
TypeError: cannot use a string pattern on a bytes-like object
>>> tn.expect([b'.{16}'], 0)
(0, <re.Match object; span=(2, 18), match=b'Seattle Communit'>, b'\r\nSeattle Communit')
>>>
History
Date User Action Args
2020-11-30 10:07:00iritkatrielsetrecipients: + iritkatriel, jackdied, r.david.murray, Joel.Lovinger, ZackerySpytz
2020-11-30 10:07:00iritkatrielsetmessageid: <1606730820.76.0.710206730855.issue14556@roundup.psfhosted.org>
2020-11-30 10:07:00iritkatriellinkissue14556 messages
2020-11-30 10:07:00iritkatrielcreate