def validate_litezip(struct):
msgs = []<EOL>def _fmt_err(err):<EOL><INDENT>return (Path(err.filename), "<STR_LIT>".format(*(err[<NUM_LIT:1>:])))<EOL><DEDENT>obj_by_type = {}<EOL>for obj in struct:<EOL><INDENT>if not is_valid_identifier(obj.id):<EOL><INDENT>msg = (obj.file.parent,<EOL>"<STR_LIT>".format(obj.id),)<EOL>logger.info("<STR_LIT>".format(*msg))<EOL>msgs.append(msg)<EOL><DEDENT>obj_by_type.setdefault(type(obj), []).append(obj)<EOL><DEDENT>for obtype in obj_by_type:<EOL><INDENT>content_msgs = list([_fmt_err(err) for err in<EOL>validate_content(*obj_by_type[obtype])])<EOL>for msg in content_msgs:<EOL><INDENT>logger.info("<STR_LIT>".format(*msg))<EOL><DEDENT>msgs.extend(content_msgs)<EOL><DEDENT>return msgs<EOL>
Validate the given litezip as `struct`.
    Returns a list of validation messages.