(
    issue_n: int, policy_breaks: List[PolicyBreak], ignore_sha: str
)
return "\n{} Incident {}({}): {}{} (Ignore with SHA: {}) ({} {})\n".format(
        format_text(">>>", STYLE["detector_line_start"]),
        issue_n,
        format_text(policy_breaks[0].policy, STYLE["detector"]),
        format_text(policy_breaks[0].break_type, STYLE["detector"]),
        validity_msg,
        format_text(ignore_sha, STYLE["ignore_sha"]),
        len(policy_breaks),
        pluralize("occurrence", len(policy_breaks), "occurrences"),
    )
Build a header for the policy break.
Build a header for the policy break.
Build a header for the policy break .
def policy_break_header(
    issue_n: int, policy_breaks: List[PolicyBreak], ignore_sha: str
) -> str:
    """
    Build a header for the policy break.
    """
    validity_msg = (
        f" (Validity: {format_text( _validity_translate[policy_breaks[0].validity], STYLE['nb_secrets'])}) "
        if policy_breaks[0].validity
        else ""
    )

    return "\n{} Incident {}({}): {}{} (Ignore with SHA: {}) ({} {})\n".format(
        format_text(">>>", STYLE["detector_line_start"]),
        issue_n,
        format_text(policy_breaks[0].policy, STYLE["detector"]),
        format_text(policy_breaks[0].break_type, STYLE["detector"]),
        validity_msg,
        format_text(ignore_sha, STYLE["ignore_sha"]),
        len(policy_breaks),
        pluralize("occurrence", len(policy_breaks), "occurrences"),
    )
def policy_break_header ( issue_n : int , policy_breaks : List [ PolicyBreak ] , ignore_sha : str ) -> str : validity_msg = ( f" (Validity: {format_text( _validity_translate[policy_breaks[0].validity], STYLE['nb_secrets'])}) " if policy_breaks [ 0 ] . validity else "" ) return "\n{} Incident {}({}): {}{} (Ignore with SHA: {}) ({} {})\n" . format ( format_text ( ">>>" , STYLE [ "detector_line_start" ] ) , issue_n , format_text ( policy_breaks [ 0 ] . policy , STYLE [ "detector" ] ) , format_text ( policy_breaks [ 0 ] . break_type , STYLE [ "detector" ] ) , validity_msg , format_text ( ignore_sha , STYLE [ "ignore_sha" ] ) , len ( policy_breaks ) , pluralize ( "occurrence" , len ( policy_breaks ) , "occurrences" ) , )