Message78918
The traceback shows that the problem is not related to the socket
created to retrieve the content of the directory listing, but
the "main" socket (the one used for the whole ftp session) used by
dir() command the retrieve the command answer code:
Traceback (most recent call last):
ftp.dir()
=> self.retrlines(cmd, func)
=> return self.voidresp()
=> line = self.getline()
=> line = self.file.readline() (ftplib.py:184)
...
socket.timeout: timed out
I don't understand why the readline() blocks. It's maybe related to
the newline: voidresp() uses getline() which reads a line using
self.file. The file is created by self.sock.makefile('r',
encoding=self.encoding) and so the newline is always \n whereas ftplib
of Python2 uses \r\n (CRLF) or \n (LF). |
|
Date |
User |
Action |
Args |
2009-01-03 01:14:59 | vstinner | set | recipients:
+ vstinner, giampaolo.rodola, ajaksu2, chris.mahan |
2009-01-03 01:14:59 | vstinner | set | messageid: <1230945299.15.0.911506327915.issue4791@psf.upfronthosting.co.za> |
2009-01-03 01:14:58 | vstinner | link | issue4791 messages |
2009-01-03 01:14:57 | vstinner | create | |
|