microsoft/vscode-eslint

Error output (in flat config) causes problems not to appear in the output channel

brettz9 opened this issue · 2 comments

With flat config at least, it seems that the presence of warnings on the command line prevent vscode from reporting anything at all.

To reproduce:

  1. Add this to a flat config file (eslint.config.js):
// Note the missing semicolon which should trigger an error
import noUseExtendNative from 'eslint-plugin-no-use-extend-native'

export default [
  {
    rules: {
      semi: ['error']
    }
  }
];
  1. Notice after a restart there are no ESLint error messages showing up when the output channel is shown.
  2. Run eslint . from a package.json script and notice the deprecation error due to the above import currently giving such an error.
  3. Change the eslint.config.js file to the following:
// Missing semi at the end
export default [
  {
    rules: {
      semi: ['error']
    }
  }
]
  1. Notice after a restart that the error shows in VSCode under problems when the output channel is shown.

@brettz9 since something like this is very version dependent (both eslint and plugins) would you be able to provide me with a GitHub repository wit a minimal setup to reproduce the problem.

Apologies, after setting up the repo, I noticed that there was in fact output, just no problems.

And that was due to using different Node versions between command line and in VSC, something resolved by #1356 (comment) .

Thanks for the help!