Open edemaine opened 3 years ago
@edemaine I am pretty sure that this fails because the ESLint server by default tries to run with the node version that ships with VS Code and therefore tries to do some asar resolving.
Can you try to use the eslint.runtime
setting and point to to you local node install. If it is on the path you can simple set it to node
.
Thanks for the quick response! I tried setting eslint.runtime
to "node"
, and ESLint server now says "running in node v15.5.1" which is the version I have installed. Unfortunately, I'm still getting the same error.
@edemaine can you please provide me with a GitHub repository I can clone that demos what you are experiencing.
Sure! Here are reproduction instructions:
git clone https://github.com/edemaine/comingle.git
choco install meteor
. meteor
within this directory (which will create a local server at http://localhost:3000
, FYI) to generate the build, which populates .meteor/build
.@edemaine can you use ESLint correctly when running in a terminal and using ESLint from the node_modules
folder using something like node node_modules\eslint\bin\eslint.js file to validate
Usually we expect a smaller reproducible case and installing something like Meteor is not what I want to do.
I tried to make a smaller reproduction, but it's tricky because the error seems to be transient, from during a build; probably the file gets created and removed before the ESLint server can access.
Fortunately, on further investigation, it seems that the error message doesn't actually cause the ESLint server to crash; it keeps going despite the transient errors.
My actual problem seems to be that I can't get ESLint to recognize *.coffee
files. I'm using the script eslint --ext .coffee .
to check all files. I added coffeescript
to eslint.probe
and "eslint.lintTask.options": "--ext .coffee"
and "eslint.options": {"extensions": [".js", ".coffee"]},
but nothing seems to run when editing a .coffee
file. I only just realized that other files (e.g. Markdown files) do correctly trigger eslint.
@edemaine just to double check. Validating coffeescript using ESLint in the terminal works (e.g. eslint --ext .coffee .
)?
Yes, correct.
I assume the probing for coffee script fails. You can always force validation using the deprecated validate
setting. I will look into making coffee script probing work.
I'm having trouble getting this extension to run at all, within a Meteor project on a Windows 10 machine. I can run
eslint .
andeslint <filename>
fine from the terminal. But in the ESLint output I get:I believe the relevant context is that Meteor creates builds in
.meteor/local
which includespackage.json
files that (on Windows) are weird Windows symlinks.What I don't understand is why this extension is looking at these files at all. I have a
package.json
at the root, and an.eslintrc.yml
. I tried addingignorePatterns: [.meteor]
, and I tried creating an.eslintignore
with contents.meteor
, but the extension still seems to be looking through all directories and callingrealpath
...