diff --git a/swh/storage/storage.py b/swh/storage/storage.py --- a/swh/storage/storage.py +++ b/swh/storage/storage.py @@ -224,6 +224,11 @@ def content_get(self, content): """Retrieve in bulk contents and their data. + This function may yield more blobs than provided sha1 identifiers, + in case they collide. + + It may also yield `None` values in case an object was not found. + Args: content: iterables of sha1 @@ -256,6 +261,11 @@ def content_get_range(self, start, end, limit=1000, db=None, cur=None): """Retrieve contents within range [start, end] bound by limit. + Note that this function may return more than one blob per hash. The + limit is enforced with multiplicity. + + It may also yield `None` values in case an object was not found. + Args: **start** (bytes): Starting identifier range (expected smaller than end)