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 aymanhs
Recipients aymanhs
Date 2009-08-27.07:18:15
SpamBayes Score 1.5015663e-09
Marked as misclassified No
Message-id <1251357498.06.0.267830127898.issue6789@psf.upfronthosting.co.za>
In-reply-to
Content
in ftplibs.storlines, a call is done on what should be a Text stream:
fp.readline()
This would work in pre 3.x as it returns bytes but now that readlines
returns a string, the call at lines 477 would fail:

  File "C:\Python31\lib\ftplib.py", line 477, in storlines
    if buf[-1] in B_CRLF: buf = buf[:-1]
TypeError: Type str doesn't support the buffer API

The readline call should then be encoded().
History
Date User Action Args
2009-08-27 07:18:18aymanhssetrecipients: + aymanhs
2009-08-27 07:18:18aymanhssetmessageid: <1251357498.06.0.267830127898.issue6789@psf.upfronthosting.co.za>
2009-08-27 07:18:16aymanhslinkissue6789 messages
2009-08-27 07:18:15aymanhscreate