From: Jelle Zijlstra Date: Mon, 13 Mar 2017 02:51:27 +0000 (-0700) Subject: ftplib.FTP.retrbinary callback gets a bytes, not a str (GH-652) X-Git-Tag: v3.7.0a1~1130 X-Git-Url: http://git.ipfire.org/gitweb.cgi?a=commitdiff_plain;h=9e52c907b5511393ab7e44321e9521fe0967e34d;p=thirdparty%2FPython%2Fcpython.git ftplib.FTP.retrbinary callback gets a bytes, not a str (GH-652) --- diff --git a/Doc/library/ftplib.rst b/Doc/library/ftplib.rst index 1153ce77ddab..7291dfe84811 100644 --- a/Doc/library/ftplib.rst +++ b/Doc/library/ftplib.rst @@ -235,7 +235,7 @@ followed by ``lines`` for the text version or ``binary`` for the binary version. Retrieve a file in binary transfer mode. *cmd* should be an appropriate ``RETR`` command: ``'RETR filename'``. The *callback* function is called for - each block of data received, with a single string argument giving the data + each block of data received, with a single bytes argument giving the data block. The optional *blocksize* argument specifies the maximum chunk size to read on the low-level socket object created to do the actual transfer (which will also be the largest size of the data blocks passed to *callback*). A