[win32] Permission denied in fancy_rename
John Arbash Meinel
john at arbash-meinel.com
Thu May 4 01:17:34 BST 2006
Robert Collins wrote:
...
>> By invoking its close method, if it's a file-like object. For other
>> objects that can be used as iterators, it will vary.
>>
>> Or, to put it another way, finalizing iterators isn't a responsibility
>> of get_bytes. It must be done in the calling code.
>
> Because of our problems with open files on windows, I think we must
> define the interface of the return value of get_bytes *so that* the
> calling code can fulfil that responsibility.
>
> Rob
>
Well, you can just make it part of the api that you must run the
generator to completion, and then the file will close itself.
def get_bytes(relpath):
fp = self.get(relpath)
... yield ...
fp.close()
John
=:->
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 254 bytes
Desc: OpenPGP digital signature
Url : https://lists.ubuntu.com/archives/bazaar/attachments/20060503/b107a207/attachment.pgp
More information about the bazaar
mailing list