2008-01-29, 11:44
I've come across a situation where if a urllib.retrieve download is cancelled (from a reporthook iscancelled check) the partially downloaded file can't be os.remove(file_name) as it throws an OSError errno 13 'permission denied' exception.
I've tried a delay loop to retry the delete but no matter what the wait period is it remains locked.
Could it be that the file is readonly until download completion, as it can be deleted if not cancelled ?
Any ideas?
Thanks
BBB
I've tried a delay loop to retry the delete but no matter what the wait period is it remains locked.
Could it be that the file is readonly until download completion, as it can be deleted if not cancelled ?
Any ideas?
Thanks
BBB