Skip to content
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

Report disables in the same manner as lints #4973

Merged
merged 6 commits into from Oct 14, 2020
Merged

Conversation

nex3
Copy link
Contributor

@nex3 nex3 commented Oct 9, 2020

Rather than returning disables that are considered "invalid" for
various reasons (such as --report-needless-disables) as a separate
list of objects that formatters must handle individually, stylelint
now converts them into standard lint warnings. This allows formatters
to automatically format them the same as normal warnings without any
extra disable-specific code.

Closes #4896

Rather than returning disables that are considered "invalid" for
various reasons (such as --report-needless-disables) as a separate
list of objects that formatters must handle individually, stylelint
now converts them into standard lint warnings. This allows formatters
to automatically format them the same as normal warnings without any
extra disable-specific code.

Closes #4896
@nex3 nex3 requested a review from jathak October 9, 2020 00:22
lib/__tests__/disableRanges.test.js Outdated Show resolved Hide resolved
@nex3 nex3 requested a review from vankop October 9, 2020 20:49
lib/needlessDisables.js Outdated Show resolved Hide resolved
lib/needlessDisables.js Show resolved Hide resolved
lib/reportDisables.js Show resolved Hide resolved
@nex3 nex3 requested a review from vankop October 13, 2020 22:52
@nex3 nex3 merged commit a0eab08 into master Oct 14, 2020
@nex3 nex3 deleted the lintlike-disable-reports branch October 14, 2020 19:51
m-allanson added a commit that referenced this pull request Nov 5, 2020
* master: (46 commits)
  Update CHANGELOG.md
  Add ignoreAtRules to property-no-unknown (#4965)
  Bump eslint from 7.11.0 to 7.12.1 (#5017)
  Bump typescript from 4.0.3 to 4.0.5 (#5016)
  Bump lint-staged from 10.4.0 to 10.5.1 (#5014)
  Bump remark-cli from 8.0.1 to 9.0.0 (#4996)
  Bump jest-circus from 26.5.3 to 26.6.1 (#5009)
  Bump got from 11.7.0 to 11.8.0 (#5007)
  Bump jest from 26.5.3 to 26.6.1 (#5008)
  Refactor formatter tests (#4988)
  Fix `isStandardSyntaxDeclaration.test.js` that use callbacks (#4972)
  Update CHANGELOG.md
  Add "comment-pattern" rule (#4962)
  Update CHANGELOG.md
  Show the pattern in "*-pattern" rule messages (#4975)
  Enable ESLint `no-shadow` and add disable comments (#4986)
  Report disables in the same manner as lints (#4973)
  Update dependencies (#4982)
  Fix some tests that use callbacks (#4970)
  Use own vendor utility instead of PostCSS (#4942) (#4963)
  ...
nex3 added a commit that referenced this pull request Feb 4, 2021
nex3 added a commit that referenced this pull request Feb 4, 2021
nex3 added a commit that referenced this pull request Feb 4, 2021
jeddy3 pushed a commit that referenced this pull request Feb 6, 2021
* Remove unused disable-reporting code

This was outmoded by #4973

* Allow disable reporting to be controlled from the config file

This will also make it easier to control disables on a file-by-file
basis once #3128 is implemented. It will also make it possible to add
finer-grained configuration to these rules in the future.

* Fix a typo

Co-authored-by: Jennifer Thakar <jathak@google.com>

* Code review changes

Co-authored-by: Jennifer Thakar <jathak@google.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Development

Successfully merging this pull request may close these issues.

Report disable errors the same way as lint errors
3 participants