Rev 5656: Merge 2.3 into trunk including fix for bug #715000 in http://bazaar.launchpad.net/~vila/bzr/integration/

Vincent Ladeuil v.ladeuil+lp at free.fr
Wed Feb 9 16:05:33 UTC 2011


At http://bazaar.launchpad.net/~vila/bzr/integration/

------------------------------------------------------------
revno: 5656 [merge]
revision-id: v.ladeuil+lp at free.fr-20110209160532-8yjz0ld4de45s321
parent: pqm at pqm.ubuntu.com-20110209104418-n3058l06ehubtl9a
parent: pqm at pqm.ubuntu.com-20110209093024-hx6rkxscaotvf0qy
committer: Vincent Ladeuil <v.ladeuil+lp at free.fr>
branch nick: trunk
timestamp: Wed 2011-02-09 17:05:32 +0100
message:
  Merge 2.3 into trunk including fix for bug #715000
added:
  bzrlib/tests/per_repository_reference/test_graph.py test_graph.py-20110208074011-b92ci87urjayd2q7-1
modified:
  bzrlib/groupcompress.py        groupcompress.py-20080705181503-ccbxd6xuy1bdnrpu-8
  bzrlib/knit.py                 knit.py-20051212171256-f056ac8f0fbe1bd9
  bzrlib/tests/per_repository_reference/__init__.py __init__.py-20080220025549-nnm2s80it1lvcwnc-2
  bzrlib/versionedfile.py        versionedfile.py-20060222045106-5039c71ee3b65490
  doc/en/release-notes/bzr-2.2.txt bzr2.2.txt-20101008081016-21wd86gpfhllpue3-39
-------------- next part --------------
=== modified file 'bzrlib/groupcompress.py'
--- a/bzrlib/groupcompress.py	2010-09-26 20:45:28 +0000
+++ b/bzrlib/groupcompress.py	2011-02-09 06:35:00 +0000
@@ -1,4 +1,4 @@
-# Copyright (C) 2008, 2009, 2010 Canonical Ltd
+# Copyright (C) 2008-2011 Canonical Ltd
 #
 # This program is free software; you can redistribute it and/or modify
 # it under the terms of the GNU General Public License as published by
@@ -1312,7 +1312,7 @@
         # KnitVersionedFiles.get_known_graph_ancestry, but they don't share
         # ancestry.
         parent_map, missing_keys = self._index.find_ancestry(keys)
-        for fallback in self._fallback_vfs:
+        for fallback in self._transitive_fallbacks():
             if not missing_keys:
                 break
             (f_parent_map, f_missing_keys) = fallback._index.find_ancestry(

=== modified file 'bzrlib/knit.py'
--- a/bzrlib/knit.py	2011-01-11 20:42:36 +0000
+++ b/bzrlib/knit.py	2011-02-09 06:35:00 +0000
@@ -1196,7 +1196,7 @@
     def get_known_graph_ancestry(self, keys):
         """Get a KnownGraph instance with the ancestry of keys."""
         parent_map, missing_keys = self._index.find_ancestry(keys)
-        for fallback in self._fallback_vfs:
+        for fallback in self._transitive_fallbacks():
             if not missing_keys:
                 break
             (f_parent_map, f_missing_keys) = fallback._index.find_ancestry(

=== modified file 'bzrlib/tests/per_repository_reference/__init__.py'
--- a/bzrlib/tests/per_repository_reference/__init__.py	2011-01-10 22:47:59 +0000
+++ b/bzrlib/tests/per_repository_reference/__init__.py	2011-02-09 06:35:00 +0000
@@ -105,6 +105,7 @@
         'bzrlib.tests.per_repository_reference.test_fetch',
         'bzrlib.tests.per_repository_reference.test_get_record_stream',
         'bzrlib.tests.per_repository_reference.test_get_rev_id_for_revno',
+        'bzrlib.tests.per_repository_reference.test_graph',
         'bzrlib.tests.per_repository_reference.test_initialize',
         'bzrlib.tests.per_repository_reference.test_unlock',
         ]

=== added file 'bzrlib/tests/per_repository_reference/test_graph.py'
--- a/bzrlib/tests/per_repository_reference/test_graph.py	1970-01-01 00:00:00 +0000
+++ b/bzrlib/tests/per_repository_reference/test_graph.py	2011-02-08 08:01:40 +0000
@@ -0,0 +1,45 @@
+# Copyright (C) 2011 Canonical Ltd
+#
+# This program is free software; you can redistribute it and/or modify
+# it under the terms of the GNU General Public License as published by
+# the Free Software Foundation; either version 2 of the License, or
+# (at your option) any later version.
+#
+# This program is distributed in the hope that it will be useful,
+# but WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+# GNU General Public License for more details.
+#
+# You should have received a copy of the GNU General Public License
+# along with this program; if not, write to the Free Software
+# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
+
+
+"""Tests for graph operations on stacked repositories."""
+
+
+from bzrlib.tests.per_repository import TestCaseWithRepository
+
+
+class TestGraph(TestCaseWithRepository):
+
+    def test_get_known_graph_ancestry_stacked(self):
+        """get_known_graph_ancestry works correctly on stacking.
+
+        See <https://bugs.launchpad.net/bugs/715000>.
+        """
+        branch_a, branch_b, branch_c, revid_1 = self.make_double_stacked_branches()
+        for br in [branch_c]:
+            self.assertEquals(
+                [revid_1],
+                br.repository.get_known_graph_ancestry([revid_1]).topo_sort())
+
+    def make_double_stacked_branches(self):
+        wt_a = self.make_branch_and_tree('a')
+        branch_a = wt_a.branch
+        branch_b = self.make_branch('b')
+        branch_b.set_stacked_on_url('../a')
+        branch_c = self.make_branch('c')
+        branch_c.set_stacked_on_url('../b')
+        revid_1 = wt_a.commit('first commit')
+        return branch_a, branch_b, branch_c, revid_1

=== modified file 'bzrlib/versionedfile.py'
--- a/bzrlib/versionedfile.py	2010-08-28 15:34:24 +0000
+++ b/bzrlib/versionedfile.py	2011-02-09 06:35:00 +0000
@@ -1193,6 +1193,19 @@
     def _extract_blocks(self, version_id, source, target):
         return None
 
+    def _transitive_fallbacks(self):
+        """Return the whole stack of fallback versionedfiles.
+
+        This VersionedFiles may have a list of fallbacks, but it doesn't
+        necessarily know about the whole stack going down, and it can't know
+        at open time because they may change after the objects are opened.
+        """
+        all_fallbacks = []
+        for a_vfs in self._fallback_vfs:
+            all_fallbacks.append(a_vfs)
+            all_fallbacks.extend(a_vfs._transitive_fallbacks())
+        return all_fallbacks
+
 
 class ThunkedVersionedFiles(VersionedFiles):
     """Storage for many versioned files thunked onto a 'VersionedFile' class.

=== modified file 'doc/en/release-notes/bzr-2.2.txt'
--- a/doc/en/release-notes/bzr-2.2.txt	2011-02-04 14:10:48 +0000
+++ b/doc/en/release-notes/bzr-2.2.txt	2011-02-09 08:24:25 +0000
@@ -2,8 +2,79 @@
 Bazaar Release Notes
 ####################
 
-.. toctree::
-   :maxdepth: 1
+.. contents:: List of Releases
+   :depth: 1
+
+bzr 2.2.5
+#########
+
+:Codename: Suggestions welcome
+:2.2.5: NOT RELEASED YET
+
+Compatibility Breaks
+********************
+
+New Features
+************
+
+Bug Fixes
+*********
+
+* Correctly handle ``bzr log`` and `get_known_graph_ancestry` on a
+  doubly-stacked branch.
+  (James Westby, Martin Pool, #715000)
+
+Improvements
+************
+
+Documentation
+*************
+
+API Changes
+***********
+
+Internals
+*********
+
+Testing
+*******
+
+
+bzr 2.2.4
+#########
+
+:2.2.4: 2011-02-04
+
+This is a bugfix release. Only one bug has been fixed, a regression from 2.2.3
+involving only certain operations with launchpad. Upgrading is recommended for
+all users on earlier 2.2 releases.
+
+Bug Fixes
+*********
+
+* Fix communications with the Launchpad web service when using
+  launchpadlib >= 1.5.5.  This was a latent bug in bzr's communication
+  with Launchpad's production instance, which only became a problem when
+  the default instance was switched from edge to production in bzr 2.2.3.
+  (Max Bowsher, #707075)
+
+
+bzr 2.2.3
+#########
+
+:2.2.3: 2011-01-20
+
+This is a bugfix release. Upgrading is recommended for all users
+on earlier 2.2 releases.
+
+Compatibility Breaks
+********************
+
+* Launchpad has announced that the ``edge.launchpad.net`` instance is
+  deprecated and may be shut down in the future
+  <http://blog.launchpad.net/general/edge-is-deprecated>.  Bazaar has therefore
+  been updated in this release to talk to the main (``launchpad.net``) servers,
+  rather than the ``edge`` ones. (Vincent Ladeuil, #583667)
 
 bzr 2.2.4
 #########



More information about the bazaar-commits mailing list