Skip to content
This repository has been archived by the owner on Nov 10, 2022. It is now read-only.

Invalid rule configuration only gives feedback on console and does not update UI at all #413

Closed
platinumazure opened this issue Sep 25, 2017 · 0 comments · Fixed by eslint/eslint#9819
Labels
triage An ESLint team member will look at this issue soon

Comments

@platinumazure
Copy link
Member

Repro steps:

  1. Enter the following into the demo:
    /* eslint no-unreachable: ["error"] */
    function foo() {
        return;
        doSomething();
    }
  2. Observe no-unreachable error
  3. Change configuration to: /* eslint no-unreachable: ["error", { someInvalidConfig: true }] */
  4. Remove the return; statement

Expected: Get an error about invalid rule configuration at some point

Actual: Previous error is stuck on the screen

Note: This also applies to lint-free code, and code will appear to remain "lint-free" even if there are actually lint problems.

@eslintbot eslintbot added the triage An ESLint team member will look at this issue soon label Sep 25, 2017
not-an-aardvark added a commit to eslint/eslint that referenced this issue Jan 7, 2018
This updates `Linter` to treat malformed configuration comments as linting errors rather than fatal issues that crash the process. Previously, this could cause surprising behavior because it was the only known instance where a problem in the source code (given a valid configuration) could cause an error to be thrown.

For example, this also fixes eslint/archive-website#413.
not-an-aardvark added a commit to eslint/eslint that referenced this issue Jan 10, 2018
…#9819)

This updates `Linter` to treat malformed configuration comments as linting errors rather than fatal issues that crash the process. Previously, this could cause surprising behavior because it was the only known instance where a problem in the source code (given a valid configuration) could cause an error to be thrown.

For example, this also fixes eslint/archive-website#413.
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
triage An ESLint team member will look at this issue soon
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants