equal
deleted
inserted
replaced
356 for i, row in enumerate(res): |
356 for i, row in enumerate(res): |
357 rid, rev, node, p1rev, p2rev, linkrev, flags = row |
357 rid, rev, node, p1rev, p2rev, linkrev, flags = row |
358 |
358 |
359 if i != rev: |
359 if i != rev: |
360 raise SQLiteStoreError( |
360 raise SQLiteStoreError( |
361 _(b'sqlite database has inconsistent ' b'revision numbers') |
361 _(b'sqlite database has inconsistent revision numbers') |
362 ) |
362 ) |
363 |
363 |
364 if p1rev == nullrev: |
364 if p1rev == nullrev: |
365 p1node = nullid |
365 p1node = nullid |
366 else: |
366 else: |
770 |
770 |
771 # This restriction is cargo culted from revlogs and makes no sense for |
771 # This restriction is cargo culted from revlogs and makes no sense for |
772 # SQLite, since columns can be resized at will. |
772 # SQLite, since columns can be resized at will. |
773 if len(tombstone) > len(self.rawdata(censornode)): |
773 if len(tombstone) > len(self.rawdata(censornode)): |
774 raise error.Abort( |
774 raise error.Abort( |
775 _(b'censor tombstone must be no longer than ' b'censored data') |
775 _(b'censor tombstone must be no longer than censored data') |
776 ) |
776 ) |
777 |
777 |
778 # We need to replace the censored revision's data with the tombstone. |
778 # We need to replace the censored revision's data with the tombstone. |
779 # But replacing that data will have implications for delta chains that |
779 # But replacing that data will have implications for delta chains that |
780 # reference it. |
780 # reference it. |
1159 return orig(ui, createopts) |
1159 return orig(ui, createopts) |
1160 |
1160 |
1161 # This restriction can be lifted once we have more confidence. |
1161 # This restriction can be lifted once we have more confidence. |
1162 if b'sharedrepo' in createopts: |
1162 if b'sharedrepo' in createopts: |
1163 raise error.Abort( |
1163 raise error.Abort( |
1164 _(b'shared repositories not supported with SQLite ' b'store') |
1164 _(b'shared repositories not supported with SQLite store') |
1165 ) |
1165 ) |
1166 |
1166 |
1167 # This filtering is out of an abundance of caution: we want to ensure |
1167 # This filtering is out of an abundance of caution: we want to ensure |
1168 # we honor creation options and we do that by annotating exactly the |
1168 # we honor creation options and we do that by annotating exactly the |
1169 # creation options we recognize. |
1169 # creation options we recognize. |
1174 } |
1174 } |
1175 |
1175 |
1176 unsupported = set(createopts) - known |
1176 unsupported = set(createopts) - known |
1177 if unsupported: |
1177 if unsupported: |
1178 raise error.Abort( |
1178 raise error.Abort( |
1179 _(b'SQLite store does not support repo creation ' b'option: %s') |
1179 _(b'SQLite store does not support repo creation option: %s') |
1180 % b', '.join(sorted(unsupported)) |
1180 % b', '.join(sorted(unsupported)) |
1181 ) |
1181 ) |
1182 |
1182 |
1183 # Since we're a hybrid store that still relies on revlogs, we fall back |
1183 # Since we're a hybrid store that still relies on revlogs, we fall back |
1184 # to using the revlogv1 backend's storage requirements then adding our |
1184 # to using the revlogv1 backend's storage requirements then adding our |