'Run all registered checks and return list of Errors and Warnings.'

def run_checks(self, app_configs=None, tags=None, include_deployment_checks=False):

    errors = []
    checks = self.get_checks(include_deployment_checks)
    if (tags is not None):
        checks = [check for check in checks if (hasattr(check, 'tags') and (not set(check.tags).isdisjoint(tags)))]
    else:
        checks = [check for check in checks if ((not hasattr(check, 'tags')) or (Tags.database not in check.tags))]
    for check in checks:
        new_errors = check(app_configs=app_configs)
        assert is_iterable(new_errors), ('The    function    %r    did    not    return    a    list.    All    functions    registered    with    the    checks    registry    must    return    a    list.' % check)
        errors.extend(new_errors)
    return errors
