def list(self, path=None, with_metadata=False, include_partitions=False):
        '''Get a list of all of bundle files in the cache. Does not return partition files'''
        import json

        sub_path = self.prefix + '/' + path.strip('/') if path else self.prefix

        l = {}

        for e in self.bucket.list(sub_path):

            path = e.name.replace(self.prefix, '', 1).strip('/')
            if path.startswith('_') or path.startswith('meta'):
                continue

            # TODO 'include_partitions' doesn't make any sense outside of ambry
            if not include_partitions and path.count('/') > 1:
                continue  # partition files

            if with_metadata:
                d = self.metadata(path)
                if d and 'identity' in d:
                    d['identity'] = json.loads(d['identity'])
            else:
                d = {}

            d['caches'] = [self.repo_id]

            if path:
                l[path] = d

        return l
Get a list of all of bundle files in the cache. Does not return partition files