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

Trying to delete non-existent .eslintcache on read-only file system #11945

Closed
cuki opened this issue Jul 4, 2019 · 0 comments

Comments

@cuki
Copy link
Contributor

commented Jul 4, 2019

Tell us about your environment

  • ESLint Version: 6.0.1
  • Node Version: 8.9.4
  • npm Version: 4.6.1

What parser (default, Babel-ESLint, etc.) are you using?
default

Please show your full configuration:

Configuration
module.exports = {
    "extends": "eslint:recommended"
};

What did you do?
Wanted to try out ESLint 6.* by running it on a simple file within Docker.

However it's trying to delete a non-existent file on a read-only part of the system (root directory of the project). While build/node_modules and src/ do have both read/write permissions.

Pretty sure this would be the case for any other restricted permission file system, for me it just happened to be in Docker.

function hello(){
  console.log('world')
}

hello();
build/node_modules/.bin/eslint --config .eslintrc.js src/test.js

What actually happened?
It seems that it tries to delete the .eslintcache file, which does not exist, on a read-only file system.

Error: EROFS: read-only file system, unlink '/project/.eslintcache'
    at Object.fs.unlinkSync (fs.js:1061:18)
    at CLIEngine.executeOnFiles (/project/build/node_modules/eslint/lib/cli-engine/cli-engine.js:735:20)
    at Object.execute (/project/build/node_modules/eslint/lib/cli.js:209:111)
    at Object.<anonymous> (/project/build/node_modules/eslint/bin/eslint.js:78:28)
    at Module._compile (module.js:643:30)
    at Object.Module._extensions..js (module.js:654:10)
    at Module.load (module.js:556:32)
    at tryModuleLoad (module.js:499:12)
    at Function.Module._load (module.js:491:3)
    at Function.Module.runMain (module.js:684:10)

What did you expect to happen?
For it to run the linter on the specified file. It should not bother trying to delete a file which does not exist.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
2 participants
You can’t perform that action at this time.