Ticket #32 (closed defect: fixed)
Exception when calling FTPHost.close after synchronize_times (Windows only)
| Reported by: | schwa | Owned by: | schwa |
|---|---|---|---|
| Priority: | critical | Milestone: | 2.4.1 |
| Component: | Library | Version: | 2.4 |
| Keywords: | exception, lrucache, Windows | Cc: |
Description (last modified by schwa) (diff)
Running the code
host = ftputil.FTPHost(hostname, user, password) host.synchronize_times() host.close()
triggers an exception
Traceback (most recent call last):
File "g:\test\test.py", line 13, in <module>
host.synchronize_times()
File "g:\test\ftputil\ftputil.py", line 896, in __exit__
self.close()
File "g:\test\ftputil\ftputil.py", line 253, in close
self.stat_cache.clear()
File "g:\test\ftputil\ftp_stat_cache.py", line 117, in clear
self.resize(0)
File "g:\test\ftputil\ftp_stat_cache.py", line 100, in resize
self._cache.size = new_size
File "g:\test\ftputil\lrucache.py", line 186, in __setattr__
del self.__dict[lru.key]
KeyError: '/htdocs/new/_ftputil_sync_'
with Python 2.6.1. This happens on Windows, but not under Ubuntu Intrepid.
(originally reported by Peter Stirling)
Attachments
Change History
Note: See
TracTickets for help on using
tickets.
