Skip to content

check-affected.sh should run the comment-lint gate so lane PRs catch it before CI #18087

Description

@kyle-sexton

Problem

Issue-lane PRs fail CI's Lint Repo comment-lint gate after they are pushed: 5 of about 12 lane PRs in the two hours to 2026-11-21T23:45Z, for example run 44962011745. Each failure costs a CI round and a fix-ci round.

The lane's only self-check is scripts/check-affected.sh --uncommitted (docs/conventions/pr-pipeline.yaml:385). scripts/check-affected-gates.txt:54 marks comment-lint as ci-only, because the code-tidying git hook runs it at commit. The lane commits through the API, and its check wrappers set core.hooksPath=/dev/null (.github/actions/collect-base-activity/action.yml:234), so the gate never runs before push.

Done when

  • scripts/check-affected.sh runs the comment-lint gate on the change, with the same diff and the same settings source (the merge-base) as CI's Lint Repo step, and fails on a comment outside the repository's posture.
  • scripts/check-affected-gates.txt lists comment-lint as a run gate, not ci-only.
  • The lane's staged base copy (.github/actions/collect-base-activity/action.yml stage_checks) includes the code-tidying files the gate needs, so the gate runs from the base copy.
  • A missing comment-lint dependency (pygments) makes the gate skip with a stated reason, not fail the lane.
  • Tests cover a clean change, a planted disallowed comment (committed and uncommitted), and the missing-dependency skip.

Activity

  1. added
    needs-triageNot yet classified. Floor until a type and one priority tier are set.
    on Nov 22, 2026
  2. github-actions commented on Nov 22, 2026

    @github-actions
    Contributor

    Size: Medium
    Complexity: Medium
    Uncertainty: Knowable
    Flags: none
    Blocked by: none
    Blast radius: scripts/check-affected.sh, scripts/check-affected-gates.txt, the stage_checks step in collect-base-activity, and their tests; read by the issue lane and anyone running the affected-checks script locally.
    Reversible: yes; revert the change and comment-lint returns to ci-only.
    Open questions: none
    I understood this as follows: issue-lane PRs commit through the API with hooks disabled, so the comment-lint gate only runs in CI. You want it to run in check-affected.sh against the same diff and merge-base settings as CI. It should be listed as a run gate and staged in the base copy. It should skip with a stated reason when pygments is missing. Tests should cover the clean, planted-comment and missing-dependency cases. The done-when list is exact, so I found nothing missing. I found no duplicate among the open issues and no merged PR that already does this.

    Automated triage. A maintainer reviews it.

  3. removed
    needs-triageNot yet classified. Floor until a type and one priority tier are set.
    on Nov 22, 2026
  4. melodic-automation-lanes commented on Nov 22, 2026

    @melodic-automation-lanes
    Contributor

    Not admitted to the issue lane yet: open pull request #18081 is for it.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    Fields

    Work status

    deferred

    Priority

    medium

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions