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

expiring-todo-comments Broken in ESlint 9.15.0 #2496

Closed
Lalem001 opened this issue Nov 15, 2024 · 7 comments · Fixed by #2497
Closed

expiring-todo-comments Broken in ESlint 9.15.0 #2496

Lalem001 opened this issue Nov 15, 2024 · 7 comments · Fixed by #2497
Labels

Comments

@Lalem001
Copy link

Lalem001 commented Nov 15, 2024

unicorn/expiring-todo-comments Broken in ESlint 9.15.0. Works fine in 9.14.0.

TypeError: Error while loading rule 'unicorn/expiring-todo-comments': Cannot read properties of undefined (reading 'decoration')

The above error occurs when reading a file that has the following comment:

// Note: If none of the slotted options are selected, select all

Relevant portion of ESLint config is:

{
  files: ['**/*'],
  extends: [eslint.configs.recommended, unicorn.configs['flat/recommended']],
  linterOptions: {
    reportUnusedDisableDirectives: true,
  },
},
@Lalem001 Lalem001 added the bug label Nov 15, 2024
@Lalem001
Copy link
Author

Lalem001 commented Nov 15, 2024

Relevant dependencies in package.json:

{
  "devDependencies": {
    "@eslint/js": "^9.15.0",
    "eslint": "^9.15.0",
    "eslint-plugin-unicorn": "^56.0.0",
  }
}

@marcalexiei
Copy link
Contributor

Might be related to eslint/eslint#19134

@Pnlvfx

This comment was marked as duplicate.

@Pnlvfx
Copy link

Pnlvfx commented Nov 18, 2024

typescript-eslint was affected and does fix it, now we have to wait for this

@ipanasenko
Copy link

They've fixed it in 8.15.0

@Lalem001
Copy link
Author

Might be related to eslint/eslint#19134

ESLint team chalked this one up to an issue with typescript-eslint which just pushed an update to fix it on their end.

They've fixed it in 8.15.0

I updated all my deps and still have the same issue. Disabling unicorn avoids the error. So the issue persists in unicorn.

renovate bot added a commit to stephenwade/festival that referenced this issue Nov 19, 2024
* Update eslint monorepo to v9.15.0

* Disable unicorn/expiring-todo-comments

sindresorhus/eslint-plugin-unicorn#2496

---------

Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
Co-authored-by: Stephen Wade <[email protected]>
@alaa-paramount
Copy link

Might be related to eslint/eslint#19134

ESLint team chalked this one up to an issue with typescript-eslint which just pushed an update to fix it on their end.

They've fixed it in 8.15.0

I updated all my deps and still have the same issue. Disabling unicorn avoids the error. So the issue persists in unicorn.

Yeah I confirm, same error here
I have typescript-eslint 8.15.0 and still getting this error on "unicorn/expiring-todo-comments"

and "TypeError: Error while loading rule 'sonarjs/no-empty-function': Cannot read properties of undefined (reading 'allow')" (but it's not relevant for this thread)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging a pull request may close this issue.

5 participants