def simple_incorrect_scan_and_codes(simple_scan):
    """
    Return a scan and error codes, representing a small mesh which produces a
    couple of known requirement and advisory statements, and the relevant
    statement codes.

    Errors as follows:
        mesh missing cf_role (but identified from datavar) --> R101
        node_lon specifies a 'bounds', which is missing --> R203
        node_lat missing units --> A204
        invalid UGRID 'Conventions' attribute --> A903

    """
    scan = simple_scan
    # Remove topology:cf_role --> R101
    del scan.variables["topology"].attributes["cf_role"]
    # Add node_lon:bounds --> R203
    scan.variables["node_lon"].attributes["bounds"] = "missing_lon_bounds"
    # Remove node_lat:units --> A204
    del scan.variables["node_lat"].attributes["units"]
    # Invalidate global 'Conventions' UGRID part --> A903
    assert scan.attributes["Conventions"] == "UGRID-1.0"
    scan.attributes["Conventions"] = "UG-1.0"
    # Also return a list of the expected statement codes.
    expected_codes = ["R101", "R203", "A204", "A903"]
    return scan, expected_codes