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

feat!: Remove valid-jsdoc and require-jsdoc #17694

Merged
merged 11 commits into from Dec 21, 2023
Merged

feat!: Remove valid-jsdoc and require-jsdoc #17694

merged 11 commits into from Dec 21, 2023

Conversation

nzakas
Copy link
Member

@nzakas nzakas commented Oct 30, 2023

Prerequisites checklist

What is the purpose of this pull request? (put an "X" next to an item)

[ ] Documentation update
[ ] Bug fix (template)
[ ] New rule (template)
[ ] Changes an existing rule (template)
[ ] Add autofix to a rule
[ ] Add a CLI option
[ ] Add something to the core
[ ] Other, please explain:

Remove rule

What changes did you make? (Give an overview)

  1. Removed valid-jsdoc rule, tests, and docs
  2. Updated rule deprecation policy

TODO: Determine if we want to remove require-jsdoc too.

Fixes #15820

Is there anything you'd like reviewers to focus on?

@eslint-github-bot eslint-github-bot bot added breaking This change is backwards-incompatible feature This change adds a new feature to ESLint labels Oct 30, 2023
@netlify
Copy link

netlify bot commented Oct 30, 2023

Deploy Preview for docs-eslint canceled.

Name Link
🔨 Latest commit 282050e
🔍 Latest deploy log https://app.netlify.com/sites/docs-eslint/deploys/65847e1e2298f5000878a782

@mdjermanovic
Copy link
Member

@nzakas you probably intended to push 3deb185 to the branch of #17696 instead of here.

@nzakas
Copy link
Member Author

nzakas commented Oct 31, 2023

Yep, just fixed it.

@@ -23,6 +23,7 @@
{ "removed": "space-in-brackets", "replacedBy": ["object-curly-spacing", "array-bracket-spacing"] },
{ "removed": "space-return-throw-case", "replacedBy": ["keyword-spacing"] },
{ "removed": "space-unary-word-ops", "replacedBy": ["space-unary-ops"] },
{ "removed": "spaced-line-comment", "replacedBy": ["spaced-comment"] }
{ "removed": "spaced-line-comment", "replacedBy": ["spaced-comment"] },
{ "removed": "valid-jsdoc", "replacedBy": [] }
Copy link
Member

Choose a reason for hiding this comment

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

We should also add require-jsdoc to this list.

Copy link
Member

Choose a reason for hiding this comment

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

We're not removing docs for removed rules. We're just updating it with the info that the rule has been removed.

For example:

https://eslint.org/docs/latest/rules/generator-star

Copy link
Member Author

Choose a reason for hiding this comment

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

Ah! Pretty sure we had a stronger visual treatment than that, though. I'll check on that too.

Copy link
Member

Choose a reason for hiding this comment

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

Yeah, it seems that on the old site that (removed) was converted to an X.

https://archive.eslint.org/docs/rules/generator-star

@nzakas nzakas changed the title feat!: Remove valid-jsdoc feat!: Remove valid-jsdoc and require-jsdoc Nov 3, 2023
Copy link

Hi everyone, it looks like we lost track of this pull request. Please review and see what the next steps are. This pull request will auto-close in 7 days without an update.

@github-actions github-actions bot added the Stale label Nov 18, 2023
@kecrily kecrily removed the Stale label Nov 19, 2023
@mdjermanovic mdjermanovic added the accepted There is consensus among the team that this change meets the criteria for inclusion label Nov 20, 2023
@@ -7,10 +7,12 @@ Balancing the trade-offs of improving a tool and the frustration these changes c

The ESLint team is committed to making upgrading as easy and painless as possible. To that end, the team has agreed upon the following set of guidelines for deprecating rules in the future. The goal of these guidelines is to allow for improvements and changes to be made without breaking existing configurations.

* Rules will never be removed from ESLint.
* Rules will never be removed from ESLint unless one of the following is true:
* The rule has been replaced by another core rule
Copy link
Member

Choose a reason for hiding this comment

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

Suggested change
* The rule has been replaced by another core rule
* The rule has been replaced by another core rule.

@@ -1774,7 +1772,7 @@ describe("CLIEngine", () => {
engine = new CLIEngine({
cwd: originalDir,
useEslintrc: false,
rules: { indent: 1, "valid-jsdoc": 0, "require-jsdoc": 0 }
rules: { indent: 1, "callback-return": 0 }
Copy link
Member

Choose a reason for hiding this comment

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

This line is causing merge conflicts. The fixed line should be rules: { eqeqeq: 1, "callback-return": 0 } (indent was replaced here with eqeqeq in #17696).

@@ -1762,7 +1760,7 @@ describe("ESLint", () => {
cwd: originalDir,
useEslintrc: false,
overrideConfig: {
rules: { indent: 1, "valid-jsdoc": 0, "require-jsdoc": 0 }
rules: { indent: 1, "callback-return": 0 }
Copy link
Member

Choose a reason for hiding this comment

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

@@ -1956,7 +1954,7 @@ describe("FlatESLint", () => {
cwd: originalDir,
overrideConfigFile: true,
overrideConfig: {
rules: { indent: 1, "valid-jsdoc": 0, "require-jsdoc": 0 }
rules: { indent: 1, "callback-return": 0 }
Copy link
Member

Choose a reason for hiding this comment

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

@mdjermanovic
Copy link
Member

There are also merge conflicts in docs/src/_data/rules.json. I think it would be better to undo changes in autogenerated files to reduce possible merge conflicts.

Copy link
Member

@mdjermanovic mdjermanovic left a comment

Choose a reason for hiding this comment

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

LGTM, thanks!

@mdjermanovic
Copy link
Member

There are merge conflicts because the two removed test files have changed in the meantime.

@nzakas nzakas marked this pull request as ready for review December 20, 2023 18:35
@nzakas nzakas requested a review from a team as a code owner December 20, 2023 18:35
Copy link
Member

@mdjermanovic mdjermanovic left a comment

Choose a reason for hiding this comment

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

Looks like 7a79445 was lost in rebase.

tests/lib/eslint/flat-eslint.js Outdated Show resolved Hide resolved
Co-authored-by: Milos Djermanovic <milos.djermanovic@gmail.com>
@nzakas
Copy link
Member Author

nzakas commented Dec 21, 2023

Thanks for that. These conflicts were getting messy.

Copy link
Member

@mdjermanovic mdjermanovic left a comment

Choose a reason for hiding this comment

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

LGTM, thanks!

@mdjermanovic mdjermanovic merged commit bdd6ba1 into main Dec 21, 2023
17 checks passed
@mdjermanovic mdjermanovic deleted the issue15820 branch December 21, 2023 18:47
bmish added a commit to bmish/eslint that referenced this pull request Dec 27, 2023
* main:
  chore: use jsdoc/no-multi-asterisks with allowWhitespace: true (eslint#17900)
  chore: fix getting scope in tests (eslint#17899)
  fix!: Parsing 'exported' comment using parseListConfig (eslint#17675)
  docs: updated examples of `max-lines` rule (eslint#17898)
  feat!: Remove valid-jsdoc and require-jsdoc (eslint#17694)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
accepted There is consensus among the team that this change meets the criteria for inclusion breaking This change is backwards-incompatible feature This change adds a new feature to ESLint
Projects
Status: Complete
Development

Successfully merging this pull request may close these issues.

Remove require-jsdoc and valid-jsdoc (and doctrine)
3 participants