diff options
author | Jürg Billeter <j@bitron.ch> | 2019-08-29 12:47:53 +0200 |
---|---|---|
committer | Jürg Billeter <j@bitron.ch> | 2019-08-29 12:49:56 +0200 |
commit | bbf949a1bf92d4efc8d3fb6f1b2ad2c1e02c6103 (patch) | |
tree | 3641846f2981bd99ed138a69ebbe7f34e3d8f856 /src/buildstream/_cas | |
parent | 204f6246cea6de2a7100da84a7d6adb005ddcae1 (diff) | |
download | buildstream-bbf949a1bf92d4efc8d3fb6f1b2ad2c1e02c6103.tar.gz |
casremote.py: Remove unused _fetch_blob() method
This removes code duplication with _CASBatchRead.
Diffstat (limited to 'src/buildstream/_cas')
-rw-r--r-- | src/buildstream/_cas/casremote.py | 19 |
1 files changed, 0 insertions, 19 deletions
diff --git a/src/buildstream/_cas/casremote.py b/src/buildstream/_cas/casremote.py index 183429a77..23240c6f7 100644 --- a/src/buildstream/_cas/casremote.py +++ b/src/buildstream/_cas/casremote.py @@ -247,25 +247,6 @@ class CASRemote(): return self.cascache.add_object(buffer=message_buffer, instance_name=self.local_cas_instance_name) - ################################################ - # Local Private Methods # - ################################################ - def _fetch_blob(self, digest): - local_cas = self.cascache._get_local_cas() - request = local_cas_pb2.FetchMissingBlobsRequest() - request.instance_name = self.local_cas_instance_name - request_digest = request.blob_digests.add() - request_digest.CopyFrom(digest) - response = local_cas.FetchMissingBlobs(request) - for blob_response in response.responses: - if blob_response.status.code == code_pb2.NOT_FOUND: - raise BlobNotFound(response.digest.hash, "Failed to download blob {}: {}".format( - blob_response.digest.hash, blob_response.status.code)) - - if blob_response.status.code != code_pb2.OK: - raise CASRemoteError("Failed to download blob {}: {}".format( - blob_response.digest.hash, blob_response.status.code)) - # Represents a batch of blobs queued for fetching. # |