/brz/remove-bazaar

To get this branch, use:
bzr branch http://gegoxaren.bato24.eu/bzr/brz/remove-bazaar

« back to all changes in this revision

Viewing changes to breezy/bzr/groupcompress.py

  • Committer: Breezy landing bot
  • Author(s): Gustav Hartvigsson
  • Date: 2021-01-10 18:46:30 UTC
  • mfrom: (7526.1.1 brz-removed-api-doc)
  • mto: This revision was merged to the branch mainline in revision 7532.
  • Revision ID: breezy.the.bot@gmail.com-20210110184630-dxu0g9dqq020uiw6
Drop documentation for removed API API.

Merged from https://code.launchpad.net/~gustav-hartvigsson/brz/removed-api-doc/+merge/396033

Show diffs side-by-side

added added

removed removed

Lines of Context:
49
49
    adapter_registry,
50
50
    AbsentContentFactory,
51
51
    ChunkedContentFactory,
 
52
    ExistingContent,
52
53
    FulltextContentFactory,
53
54
    VersionedFilesWithFallbacks,
 
55
    UnavailableRepresentation,
54
56
    )
55
57
 
56
58
# Minimum number of uncompressed bytes to try fetch at once when retrieving
482
484
                return self._chunks
483
485
            else:
484
486
                return osutils.chunks_to_lines(self._chunks)
485
 
        raise errors.UnavailableRepresentation(self.key, storage_kind,
 
487
        raise UnavailableRepresentation(self.key, storage_kind,
486
488
                                               self.storage_kind)
487
489
 
488
490
    def iter_bytes_as(self, storage_kind):
492
494
            return iter(self._chunks)
493
495
        elif storage_kind == 'lines':
494
496
            return iter(osutils.chunks_to_lines(self._chunks))
495
 
        raise errors.UnavailableRepresentation(self.key, storage_kind,
 
497
        raise UnavailableRepresentation(self.key, storage_kind,
496
498
                                               self.storage_kind)
497
499
 
498
500
 
863
865
        """
864
866
        if length == 0:  # empty, like a dir entry, etc
865
867
            if nostore_sha == _null_sha1:
866
 
                raise errors.ExistingContent()
 
868
                raise ExistingContent()
867
869
            return _null_sha1, 0, 0, 'fulltext'
868
870
        # we assume someone knew what they were doing when they passed it in
869
871
        if expected_sha is not None:
872
874
            sha1 = osutils.sha_strings(chunks)
873
875
        if nostore_sha is not None:
874
876
            if sha1 == nostore_sha:
875
 
                raise errors.ExistingContent()
 
877
                raise ExistingContent()
876
878
        if key[-1] is None:
877
879
            key = key[:-1] + (b'sha1:' + sha1,)
878
880
 
1833
1835
                    continue
1834
1836
            try:
1835
1837
                chunks = record.get_bytes_as('chunked')
1836
 
            except errors.UnavailableRepresentation:
 
1838
            except UnavailableRepresentation:
1837
1839
                adapter_key = record.storage_kind, 'chunked'
1838
1840
                adapter = get_adapter(adapter_key)
1839
1841
                chunks = adapter.get_bytes(record, 'chunked')