def expand_flush_lists(self, obj_keys, flush_keys):
        log.debug('in expand_flush_lists')
        obj_keys = set(obj_keys)
        search_keys = flush_keys = set(flush_keys)

        # Add other flush keys from the lists, which happens when a parent
        # object includes a foreign key.
        while 1:
            new_keys = set()
            for key in self.get_flush_lists(search_keys):
                if key.startswith(config.FLUSH):
                    new_keys.add(key)
                else:
                    obj_keys.add(key)
            if new_keys:
                log.debug('search for %s found keys %s' % (search_keys, new_keys))
                flush_keys.update(new_keys)
                search_keys = new_keys
            else:
                return obj_keys, flush_keys
Marks the result database as containing complete results.
dataset/ETHPy150Open django-cache-machine/django-cache-machine/caching/invalidation.py/Invalidator.expand_flush_lists--crossover with--dataset/ETHPy150Open GoogleCloudPlatform/python-compat-runtime/appengine-compat/exported_appengine_sdk/google/appengine/tools/bulkloader.py/ResultDatabase.ResultsComplete