mathlibtools/lib.py
def find_all(self, rev: Commit) -> Tuple[contextlib.ExitStack, List[OleanCache]]:
        """
        Find all closest ancestors that have a cache. Returns a tuple where the
        first result is a contextmanager that will close any unused http requests
        """
        caches = []
        with contextlib.ExitStack() as stack:
            for parent_commit, prune in visit_ancestors(rev):
                cache = self.find_exact(parent_commit)
                if cache is None:
                    log.info(f"No cache available for revision {short_sha(parent_commit)}")
                else:
                    stack.enter_context(cache)  # ensure we do not leak requests
                    caches.append(cache)
                    prune()  # do not visit the ancestors of this commit
            return stack.pop_all(), caches

        # https://github.com/python/mypy/issues/7726
        assert False

        Find all closest ancestors that have a cache. Returns a tuple where the
        first result is a contextmanager that will close any unused http requests
        
Find all closest ancestors that have a cache. Returns a tuple where the
first result is a contextmanager that will close any unused http requests
Find all closest ancestors that have a cache . Returns a tuple where the first result is a contextmanager that will close any unused http requests
def find_all(self, rev: Commit) -> Tuple[contextlib.ExitStack, List[OleanCache]]:
        caches = []
        with contextlib.ExitStack() as stack:
            for parent_commit, prune in visit_ancestors(rev):
                cache = self.find_exact(parent_commit)
                if cache is None:
                    log.info(f"No cache available for revision {short_sha(parent_commit)}")
                else:
                    stack.enter_context(cache)  
                    caches.append(cache)
                    prune()  
            return stack.pop_all(), caches
        assert False
def find_all ( self , rev : Commit ) -> Tuple [ contextlib . ExitStack , List [ OleanCache ] ] : caches = [ ] with contextlib . ExitStack ( ) as stack : for parent_commit , prune in visit_ancestors ( rev ) : cache = self . find_exact ( parent_commit ) if cache is None : log . info ( f"No cache available for revision {short_sha(parent_commit)}" ) else : stack . enter_context ( cache ) caches . append ( cache ) prune ( ) return stack . pop_all ( ) , caches assert False
Find all closest ancestors that have a cache.
Find all closest ancestors that have a cache .
"""
        Find all closest ancestors that have a cache. Returns a tuple where the
        first result is a contextmanager that will close any unused http requests
        """ # ensure we do not leak requests # do not visit the ancestors of this commit # https://github.com/python/mypy/issues/7726
self
rev
Commit