Issue 972332: urllib2 FTPHandler bugs (original) (raw)

This uncomments a couple of failing tests in test_urllib2.py, and fixes the corresponding bugs:

  1. The first bug was half-fixed since I wrote the test. Ports in FTP URLs are now correctly handled. However, the type of the port argument passed to ftplib.FTP.connect() is incorrect (is a string, should be an integer).

  2. The ftp://example.com/foo.txt;type=a syntax is implemented but broken.