Issue8594
Created on 2010-05-01 20:33 by giampaolo.rodola, last changed 2011-03-08 20:38 by giampaolo.rodola. This issue is now closed.
| Files | ||||
|---|---|---|---|---|
| File name | Uploaded | Description | Edit | |
| ftplib_source_address.patch | giampaolo.rodola, 2010-05-01 20:32 | review | ||
| ftplib_source_address.patch | giampaolo.rodola, 2011-02-26 18:26 | |||
| test_ftplib-leak.diff | nadeem.vawda, 2011-03-06 20:17 | |||
| Messages (12) | |||
|---|---|---|---|
| msg104749 - (view) | Author: Giampaolo Rodola' (giampaolo.rodola) * | Date: 2010-05-01 20:32 | |
Similarly to issue 3972 the patch in attachment adds a new "source_address" option to FTP class to bind to a specific address when connecting to a remote FTP server. It must be noted that this gets done for both control and passive data connections (client connecting to server). The latter one solves issue 1661754. |
|||
| msg104753 - (view) | Author: Antoine Pitrou (pitrou) * | Date: 2010-05-01 22:01 | |
You should not use find_unused_port(), because it causes problems on some Windows buildbot. Also, there's something fishy in your patch, because you never set self.source_address. |
|||
| msg104805 - (view) | Author: Giampaolo Rodola' (giampaolo.rodola) * | Date: 2010-05-02 21:36 | |
> You should not use find_unused_port() I agree find_unused_port() is the wrong approach in general, but in this case I think there's nothing we can do about it. > you never set self.source_address. You're right, I should set it in connect() method. I'm going to attach a new patch including documentation. |
|||
| msg129582 - (view) | Author: Giampaolo Rodola' (giampaolo.rodola) * | Date: 2011-02-26 18:26 | |
Patch in attachment set source_address attribute and updates doc. It still keeps using support.find_unused_port() which is also used in test_socket.py though [1], so it shouldn't cause problems. http://svn.python.org/view/python/trunk/Lib/test/test_socket.py?r1=77263&r2=77262&pathrev=77263 |
|||
| msg129717 - (view) | Author: Giampaolo Rodola' (giampaolo.rodola) * | Date: 2011-02-28 19:20 | |
Committed in r88679. |
|||
| msg130188 - (view) | Author: Nadeem Vawda (nadeem.vawda) * | Date: 2011-03-06 20:17 | |
test_source_address_passive_connection() raises a ResourceWarning. Fix attached. |
|||
| msg130191 - (view) | Author: Giampaolo Rodola' (giampaolo.rodola) * | Date: 2011-03-06 21:05 | |
Thanks. Committed in r88761. |
|||
| msg130192 - (view) | Author: Antoine Pitrou (pitrou) * | Date: 2011-03-06 21:11 | |
Giampaolo, can you make your commit on the Mercurial repo instead? See http://mail.python.org/pipermail/python-dev/2011-March/108738.html |
|||
| msg130238 - (view) | Author: Giampaolo Rodola' (giampaolo.rodola) * | Date: 2011-03-07 08:14 | |
Committed in r68309. |
|||
| msg130239 - (view) | Author: Giampaolo Rodola' (giampaolo.rodola) * | Date: 2011-03-07 08:15 | |
Ok, that wasn't r68309. =) I'm not sure what revision number is now that we're using mercurial. |
|||
| msg130242 - (view) | Author: Nadeem Vawda (nadeem.vawda) * | Date: 2011-03-07 08:56 | |
I'm not seeing the commit anywhere. Did you perhaps forget to "hg push" after committing? |
|||
| msg130370 - (view) | Author: Roundup Robot (python-dev) | Date: 2011-03-08 20:33 | |
New changeset 7f605fa1688d by Giampaolo Rodol�� in branch 'default': #8594: fix ResourceWarning in test_ftplib.py - patch by Nadeem Vawda. http://hg.python.org/cpython/rev/7f605fa1688d |
|||
| History | |||
|---|---|---|---|
| Date | User | Action | Args |
| 2011-03-08 20:38:34 | giampaolo.rodola | set | status: open -> closed nosy: pitrou, giampaolo.rodola, nadeem.vawda, r.david.murray, python-dev |
| 2011-03-08 20:33:33 | python-dev | set | nosy:
+ python-dev messages: + msg130370 |
| 2011-03-07 08:56:31 | nadeem.vawda | set | nosy:
pitrou, giampaolo.rodola, nadeem.vawda, r.david.murray messages: + msg130242 |
| 2011-03-07 08:15:47 | giampaolo.rodola | set | nosy:
pitrou, giampaolo.rodola, nadeem.vawda, r.david.murray messages: + msg130239 |
| 2011-03-07 08:14:50 | giampaolo.rodola | set | status: pending -> open nosy: pitrou, giampaolo.rodola, nadeem.vawda, r.david.murray messages: + msg130238 |
| 2011-03-06 21:11:56 | pitrou | set | status: closed -> pending nosy: pitrou, giampaolo.rodola, nadeem.vawda, r.david.murray messages: + msg130192 |
| 2011-03-06 21:05:05 | giampaolo.rodola | set | status: pending -> closed nosy: pitrou, giampaolo.rodola, nadeem.vawda, r.david.murray messages: + msg130191 |
| 2011-03-06 20:23:56 | pitrou | set | status: closed -> pending nosy: pitrou, giampaolo.rodola, nadeem.vawda, r.david.murray |
| 2011-03-06 20:17:13 | nadeem.vawda | set | files:
+ test_ftplib-leak.diff nosy: + nadeem.vawda messages: + msg130188 |
| 2011-02-28 19:30:14 | giampaolo.rodola | set | status: open -> closed nosy: pitrou, giampaolo.rodola, r.david.murray resolution: fixed |
| 2011-02-28 19:20:21 | giampaolo.rodola | set | nosy:
pitrou, giampaolo.rodola, r.david.murray messages: + msg129717 versions: + Python 3.3, - Python 3.2 |
| 2011-02-26 18:26:55 | giampaolo.rodola | set | files:
+ ftplib_source_address.patch nosy: pitrou, giampaolo.rodola, r.david.murray messages: + msg129582 |
| 2010-09-04 00:09:11 | pitrou | set | assignee: giampaolo.rodola |
| 2010-05-02 21:36:15 | giampaolo.rodola | set | messages: + msg104805 |
| 2010-05-01 22:01:55 | pitrou | set | messages: + msg104753 |
| 2010-05-01 20:39:48 | giampaolo.rodola | link | issue1661754 superseder |
| 2010-05-01 20:33:01 | giampaolo.rodola | create | |