# HG changeset patch # User domruf # Date 1459450403 -7200 # Node ID fc8a5cbfa0da0f385cbd4f70be1fbd1db604ddc8 # Parent 5a47ce11427c207167c089e89bdf9677ccb01b91 compare: close Dulwich internals for Git repositories to avoid leaking open files Fix failing test_compare.py on Windows by explicitly closing internal object_store objects. diff -r 5a47ce11427c -r fc8a5cbfa0da kallithea/controllers/compare.py --- a/kallithea/controllers/compare.py Mon Apr 04 23:34:30 2016 +0200 +++ b/kallithea/controllers/compare.py Thu Mar 31 20:53:23 2016 +0200 @@ -130,6 +130,9 @@ else: # no changesets from other repo, ancestor is the other_rev ancestor = other_rev + # dulwich 0.9.9 doesn't have a Repo.close() so we have to mess with internals: + gitrepo.object_store.close() + gitrepo_remote.object_store.close() else: so, se = org_repo.run_git_command(