Skip to content

[ci] [R-package] Add period after specified linter names in nolint comments #6950

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 2 commits into from
Jun 21, 2025

Conversation

nicklamiller
Copy link
Contributor

@nicklamiller nicklamiller commented Jun 21, 2025

Fixes: #6948

Adds periods after specified linter names in nolint comments so that only those linters are ignored. This was fairly straightforward, just a couple things to note:

  • In a couple places square brackets were used for linters e.g. [unused_import]. For these, I've removed the square brackets which is consistent with how linters are specified in the majority of other nolint comments.
  • Almost all lines without the trailing period only violated their specified linter so didn't have to change code or specify extra linters (with the exception of two lines that require("processx")).

Made sure there are no other nolint lines without the trailing period with:

grep -R "nolint:" . | grep -v '\.$'

@nicklamiller nicklamiller changed the title [R-package] Add period after specified linter names in nolint comments [ci] [R-package] Add period after specified linter names in nolint comments Jun 21, 2025
Copy link
Collaborator

@jameslamb jameslamb left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks for doing this and for correcting my understanding of how {lintr} works!

@jameslamb jameslamb merged commit e7c6c43 into microsoft:master Jun 21, 2025
51 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

[ci] [R-package] some {lintr} warnings may be ignored because of #nolint comment spelling
2 participants