1719
1719
self._reconcile_does_inventory_gc = True
1720
1720
self._reconcile_fixes_text_parents = True
1721
1721
self._reconcile_backsup_inventory = False
1722
self._fetch_order = 'unsorted'
1722
self._fetch_order = 'unordered'
1724
1724
def _warn_if_deprecated(self):
1725
# This class isn't deprecated
1725
# This class isn't deprecated, but one sub-format is
1726
if isinstance(self._format, RepositoryFormatKnitPack5RichRootBroken):
1727
from bzrlib import repository
1728
if repository._deprecation_warning_done:
1730
repository._deprecation_warning_done = True
1731
warning("Format %s for %s is deprecated - please use"
1732
" 'bzr upgrade --1.6.1-rich-root'"
1733
% (self._format, self.bzrdir.transport.base))
1728
1735
def _abort_write_group(self):
1729
1736
self._pack_collection._abort_write_group()
2088
2095
class RepositoryFormatKnitPack5RichRoot(RepositoryFormatPack):
2096
"""A repository with rich roots and stacking.
2098
New in release 1.6.1.
2100
Supports stacking on other repositories, allowing data to be accessed
2101
without being stored locally.
2104
repository_class = KnitPackRepository
2105
_commit_builder_class = PackRootCommitBuilder
2106
rich_root_data = True
2107
supports_tree_reference = False # no subtrees
2108
_serializer = xml6.serializer_v6
2109
supports_external_lookups = True
2111
def _get_matching_bzrdir(self):
2112
return bzrdir.format_registry.make_bzrdir(
2115
def _ignore_setting_bzrdir(self, format):
2118
_matchingbzrdir = property(_get_matching_bzrdir, _ignore_setting_bzrdir)
2120
def check_conversion_target(self, target_format):
2121
if not target_format.rich_root_data:
2122
raise errors.BadConversionTarget(
2123
'Does not support rich root data.', target_format)
2125
def get_format_string(self):
2126
"""See RepositoryFormat.get_format_string()."""
2127
return "Bazaar RepositoryFormatKnitPack5RichRoot (bzr 1.6.1)\n"
2129
def get_format_description(self):
2130
return "Packs 5 rich-root (adds stacking support, requires bzr 1.6.1)"
2133
class RepositoryFormatKnitPack5RichRootBroken(RepositoryFormatPack):
2089
2134
"""A repository with rich roots and external references.
2091
2136
New in release 1.6.
2093
2138
Supports external lookups, which results in non-truncated ghosts after
2094
2139
reconcile compared to pack-0.92 formats.
2141
This format was deprecated because the serializer it uses accidentally
2142
supported subtrees, when the format was not intended to. This meant that
2143
someone could accidentally fetch from an incorrect repository.
2097
2146
repository_class = KnitPackRepository
2115
2164
if not target_format.rich_root_data:
2116
2165
raise errors.BadConversionTarget(
2117
2166
'Does not support rich root data.', target_format)
2119
2168
def get_format_string(self):
2120
2169
"""See RepositoryFormat.get_format_string()."""
2121
2170
return "Bazaar RepositoryFormatKnitPack5RichRoot (bzr 1.6)\n"
2123
2172
def get_format_description(self):
2124
return "Packs 5 rich-root (adds stacking support, requires bzr 1.6)"
2173
return ("Packs 5 rich-root (adds stacking support, requires bzr 1.6)"
2127
2177
class RepositoryFormatPackDevelopment0(RepositoryFormatPack):