[MERGE] Remove specialized has_revisions() implementation.
Jelmer Vernooij
jelmer at samba.org
Fri Jul 4 11:25:23 BST 2008
Am Freitag, den 04.07.2008, 12:20 +0200 schrieb Jelmer Vernooij:
> The attached patch removes an unnecessary implementation of
> has_revisions() in the pack repository code. The generic
> implementation works just as well and does ask fallback repositories.
>
> This is necessary to allow bzr-svn to create stacked branches (which I
> can now successfully create, although they're quite slow at the moment).
Argh, I should stop using lp:bzr since it is out of date and thus makes
the diff in my bundle much larger than it should be.
The actual change is pretty small:
=== modified file 'bzrlib/repofmt/pack_repo.py'
--- bzrlib/repofmt/pack_repo.py 2008-06-17 05:02:34 +0000
+++ bzrlib/repofmt/pack_repo.py 2008-07-04 09:36:06 +0000
@@ -1800,17 +1800,6 @@
found_parents[key[0]] = parents
return found_parents
- def has_revisions(self, revision_ids):
- """See Repository.has_revisions()."""
- revision_ids = set(revision_ids)
- result = revision_ids.intersection(
- set([None, _mod_revision.NULL_REVISION]))
- revision_ids.difference_update(result)
- index = self._pack_collection.revision_index.combined_index
- keys = [(revision_id,) for revision_id in revision_ids]
- result.update(node[1][0] for node in index.iter_entries(keys))
- return result
-
def _make_parents_provider(self):
return graph.CachingParentsProvider(self)
Cheers,
Jelmer
--
Jelmer Vernooij <jelmer at samba.org> - http://samba.org/~jelmer/
Jabber: jelmer at jabber.fsfe.org
More information about the bazaar
mailing list