Uh oh!
There was an error while loading. Please reload this page.
fix(ci): ignore paths in merge queue (lints-only) - #7332
Conversation
WalkthroughNine GitHub Actions lint workflows (actions-lint, docker-lint, docs-check, go-lint, link-check, lists-lint, rubocop, shellcheck, yaml-lint) each receive a new preliminary "changes" job using dorny/paths-filter to detect relevant file modifications, exposing a changesFound output. Existing lint jobs are updated with needs/if conditions to run only when changes are detected, addressing merge_group's lack of path-filter support. ChangesWorkflow gating for conditional lint execution
Estimated code review effort: 2 (Simple) | ~12 minutes Possibly related PRs
Suggested labels: Suggested reviewers: 🚥 Pre-merge checks | ✅ 5✅ Passed checks (5 passed)
✨ Finishing Touches🧪 Generate unit tests (beta)
✨ Simplify code
Comment |
There was a problem hiding this comment.
Actionable comments posted: 6
🧹 Nitpick comments (1)
.github/workflows/link-check.yml (1)
42-46: 🚀 Performance & Scalability | 🔵 Trivial | ⚡ Quick winFilter scope is broader than what's actually linted.
The filter matches
**.md,**.mdx,**.htmlrecursively, but thelycheestep only scans./*.mdand./AGENTS.md(top-level, not recursive). Nested markdown/HTML changes will trigger the job even though they aren't scanned, partially defeating the CI-time-saving goal of this PR.♻️ Narrow the filter to match actual scan scope
filters: | changesFound: - - '**.md'- - '**.mdx'- - '**.html'+ - '*.md'+ - 'AGENTS.md' - '.github/workflows/link-check.yml'🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the rest with a brief reason, keep changes minimal, and validate. In @.github/workflows/link-check.yml around lines 42 - 46, The path filter is broader than the files actually checked by the link checker, so update the `changesFound` patterns in the link-check workflow to match the `lychee` scan scope. Use the workflow’s existing `lychee` step as the source of truth and narrow the recursive markdown/HTML globs so only top-level files that are truly scanned will trigger the job. Keep the `.github/workflows/link-check.yml` self-watch entry intact.
🤖 Prompt for all review comments with AI agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.
Inline comments:
In @.github/workflows/actions-lint.yml:
- Line 36: The checkout step in the actions-lint workflow should not persist
credentials because it is read-only and only used for path filtering. Update the
actions/checkout usage in the workflow to set persist-credentials to false so no
token is retained after the checkout step.
In @.github/workflows/docker-lint.yml:
- Line 40: The read-only checkout in the docker-lint workflow is missing the
same credentials hardening used elsewhere. Update the actions/checkout step in
the docker-lint job to set persist-credentials to false, matching the pattern
from the changes job in actions-lint.yml and keeping the checkout read-only.
In @.github/workflows/docs-check.yml:
- Line 40: The read-only checkout in the docs-check workflow still uses
actions/checkout without disabling stored credentials. Update the checkout step
to set persist-credentials to false so the repo token is not retained; this
applies to the checkout entry in the workflow and should be changed directly on
the actions/checkout invocation.
In @.github/workflows/go-lint.yml:
- Around line 46-51: The go-lint workflow filter is missing some Go source
paths, so changes under tools/prometheus_metrics_validator/** will not trigger
the job. Update the paths-filter configuration in the go-lint workflow to
include that directory, or replace the current narrow Go path entries with a
broader matcher such as **/*.go if the lint job should run for all Go source
changes. Use the existing changesFound filter block as the place to make this
adjustment.
In @.github/workflows/shellcheck.yml:
- Line 34: The checkout step is using actions/checkout@v7 without disabling
persisted credentials; update the shellcheck workflow’s checkout job to set
persist-credentials to false on the read-only checkout. Locate the
actions/checkout invocation in the workflow and add the credential persistence
override so this job cannot reuse the default token after checkout.
In @.github/workflows/yaml-lint.yml:
- Line 36: The checkout step in the YAML lint workflow uses actions/checkout
without disabling credential persistence; update the read-only checkout to set
persist-credentials to false. Make this change on the checkout action used in
the workflow so it matches the other read-only jobs and avoids leaving Git
credentials available after checkout.
---
Nitpick comments:
In @.github/workflows/link-check.yml:
- Around line 42-46: The path filter is broader than the files actually checked
by the link checker, so update the `changesFound` patterns in the link-check
workflow to match the `lychee` scan scope. Use the workflow’s existing `lychee`
step as the source of truth and narrow the recursive markdown/HTML globs so only
top-level files that are truly scanned will trigger the job. Keep the
`.github/workflows/link-check.yml` self-watch entry intact.
🪄 Autofix (Beta)
Fix all unresolved CodeRabbit comments on this PR:
- Push a commit to this branch (recommended)
- Create a new PR with the fixes
ℹ️ Review info
⚙️ Run configuration
Configuration used: Repository UI
Review profile: CHILL
Plan: Pro
Run ID: 9a66ace6-ba5e-449d-9058-ecc58ae03e75
📒 Files selected for processing (9)
.github/workflows/actions-lint.yml.github/workflows/docker-lint.yml.github/workflows/docs-check.yml.github/workflows/go-lint.yml.github/workflows/link-check.yml.github/workflows/lists-lint.yml.github/workflows/rubocop.yml.github/workflows/shellcheck.yml.github/workflows/yaml-lint.yml
🔗 Linked repositories identified
CodeRabbit considers these linked repositories for cross-repo context during reviews:
filecoin-project/lotus(manual)
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
Summary of changes
Changes introduced in this pull request:
Reference issue to close (if applicable)
Closes
Other information and links
Change checklist
Outside contributions
Summary by CodeRabbit