[win32] Permission denied in fancy_rename

John Arbash Meinel john at arbash-meinel.com
Tue May 2 14:29:54 BST 2006


Alexander Belchenko wrote:
> Just for completing the picture.
> 
> Attached log from one of failed test. I add to fancy_rename simple
> logging statement:
> 
>     mutter("fancy_rename(%r, %r, %r, %r)", old, new, rename_func,
> unlink_func)
> 
> From attached log you can see that all looks correct. So, most likely
> reason to fail fancy_rename is file does not closed after using.
> 
> Here is state of directory in which fancy_rename fails (state after
> testing):
> 
> Directory content of
> E:\work\Python\bzr\bzr.dev.bialix\test0000.tmp\ns.test_reconcile.TestsNeedingReweave.test_reweave_inventory_wi
> 
> thout_revision(RepositoryFormatKnit1)\inventory_without_revision\.bzr\repository

...

> fancy_rename(u'E:/work/Python/bzr/bzr.dev.bialix/test0000.tmp/ns.test_reconcile.TestsNeedingReweave.test_reweave_inventory_without_revision(RepositoryFormatKnit1)/inventory_without_revision/.bzr/repository/lock/pending.7ezly2dzq6adehuraynt.tmp/info.1312.bialix.tmp', u'E:/work/Python/bzr/bzr.dev.bialix/test0000.tmp/ns.test_reconcile.TestsNeedingReweave.test_reweave_inventory_without_revision(RepositoryFormatKnit1)/inventory_without_revision/.bzr/repository/lock/pending.7ezly2dzq6adehuraynt.tmp/info', <built-in function rename>, <built-in function unlink>)
> Garbage inventory {missing} found.
> fancy_rename(u'E:/work/Python/bzr/bzr.dev.bialix/test0000.tmp/ns.test_reconcile.TestsNeedingReweave.test_reweave_inventory_without_revision(RepositoryFormatKnit1)/inventory_without_revision/.bzr/repository/inventory.backup.kndx.tmp.1312.bialix.tmp', u'E:/work/Python/bzr/bzr.dev.bialix/test0000.tmp/ns.test_reconcile.TestsNeedingReweave.test_reweave_inventory_without_revision(RepositoryFormatKnit1)/inventory_without_revision/.bzr/repository/inventory.backup.kndx.tmp', <built-in function rename>, <built-in function unlink>)
> fancy_rename(u'E:/work/Python/bzr/bzr.dev.bialix/test0000.tmp/ns.test_reconcile.TestsNeedingReweave.test_reweave_inventory_without_revision(RepositoryFormatKnit1)/inventory_without_revision/.bzr/repository/inventory.backup.knit.1312.bialix.tmp', u'E:/work/Python/bzr/bzr.dev.bialix/test0000.tmp/ns.test_reconcile.TestsNeedingReweave.test_reweave_inventory_without_revision(RepositoryFormatKnit1)/inventory_without_revision/.bzr/repository/inventory.backup.knit', <built-in function rename>, <built-in function unlink>)
> fancy_rename(u'E:/work/Python/bzr/bzr.dev.bialix/test0000.tmp/ns.test_reconcile.TestsNeedingReweave.test_reweave_inventory_without_revision(RepositoryFormatKnit1)/inventory_without_revision/.bzr/repository/inventory.new.knit.1312.bialix.tmp', u'E:/work/Python/bzr/bzr.dev.bialix/test0000.tmp/ns.test_reconcile.TestsNeedingReweave.test_reweave_inventory_without_revision(RepositoryFormatKnit1)/inventory_without_revision/.bzr/repository/inventory.new.knit', <built-in function rename>, <built-in function unlink>)
> readv coalesced 1 reads.
> readv coalesced 1 reads.
> old data in transaction in VersionedFileStore(u'E:/work/Python/bzr/bzr.dev.bialix/test0000.tmp/ns.test_reconcile.TestsNeedingReweave.test_reweave_inventory_without_revision(RepositoryFormatKnit1)/inventory_without_revision/.bzr/repository/') for inventory
> fancy_rename(u'E:/work/Python/bzr/bzr.dev.bialix/test0000.tmp/ns.test_reconcile.TestsNeedingReweave.test_reweave_inventory_without_revision(RepositoryFormatKnit1)/inventory_without_revision/.bzr/repository/inventory.kndx.tmp.1312.bialix.tmp', u'E:/work/Python/bzr/bzr.dev.bialix/test0000.tmp/ns.test_reconcile.TestsNeedingReweave.test_reweave_inventory_without_revision(RepositoryFormatKnit1)/inventory_without_revision/.bzr/repository/inventory.kndx.tmp', <built-in function rename>, <built-in function unlink>)
> fancy_rename(u'E:/work/Python/bzr/bzr.dev.bialix/test0000.tmp/ns.test_reconcile.TestsNeedingReweave.test_reweave_inventory_without_revision(RepositoryFormatKnit1)/inventory_without_revision/.bzr/repository/inventory.knit.1312.bialix.tmp', u'E:/work/Python/bzr/bzr.dev.bialix/test0000.tmp/ns.test_reconcile.TestsNeedingReweave.test_reweave_inventory_without_revision(RepositoryFormatKnit1)/inventory_without_revision/.bzr/repository/inventory.knit', <built-in function rename>, <built-in function unlink>)
> 


Well, these lines show me that it found a problem with the inventory,
and felt that it had to reconcile it. So the specific problem isn't in
the getting, but in the reweaving. Which is useful to know, and probably
also explains why the old file is still open. (We read in the old
inventory, found it was lacking, and tried to update it).

I don't have any specific patches, but at least we have a good place to
look.

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/20060502/208b3584/attachment.pgp 


More information about the bazaar mailing list