question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Test Discovery failed: Error: EISDIR: illegal operation on a directory, read

See original GitHub issue

Environment data

VS Code version: November 2017 (version 1.19) Python Extension version: Version 0.9.0 (14 December 2017) Python Version: 2.7.14 OS and version: OSX 10.13.1

Actual behavior

Test discovery is not working.

Steps to reproduce:

  • Update VSCode to 1.19
  • Try to run test discovery

Logs

Output from Python output panel

Test Discovery failed: 
Error: EISDIR: illegal operation on a directory, read
Test Discovery failed: 
Error: EISDIR: illegal operation on a directory, read

Output from Console window (Help->Developer Tools menu)

Extension Host] Failed to parse env file Error: EISDIR: illegal operation on a directory, read
	at Object.fs.readSync (fs.js:682:19)
	at tryReadSync (fs.js:480:20)
	at Object.fs.readFileSync (fs.js:517:19)
	at Object.exports.wrapFsWithAsar.fs.readFileSync (ELECTRON_ASAR.js:505:29)
	at Object.parseEnvFile (/Users/pedromelo/.vscode/extensions/ms-python.python-0.9.0/out/client/common/envFileParser.js:26:23)
	at Object.getCustomEnvVarsSync (/Users/pedromelo/.vscode/extensions/ms-python.python-0.9.0/out/client/common/utils.js:388:38)
	at JediProxy.onConfigChanged (/Users/pedromelo/.vscode/extensions/ms-python.python-0.9.0/out/client/providers/jediProxy.js:519:47)
	at new JediProxy (/Users/pedromelo/.vscode/extensions/ms-python.python-0.9.0/out/client/providers/jediProxy.js:132:14)
	at JediFactory.getJediProxyHandler (/Users/pedromelo/.vscode/extensions/ms-python.python-0.9.0/out/client/languageServices/jediProxyFactory.js:27:31)
	at ItemInfoSource.<anonymous> (/Users/pedromelo/.vscode/extensions/ms-python.python-0.9.0/out/client/providers/itemInfoSource.js:74:43)
t.log @ console.ts:123
console.ts:123 [Extension Host] Failed to parse env file Error: EISDIR: illegal operation on a directory, read
	at Object.fs.readSync (fs.js:682:19)
	at tryReadSync (fs.js:480:20)
	at Object.fs.readFileSync (fs.js:517:19)
	at Object.exports.wrapFsWithAsar.fs.readFileSync (ELECTRON_ASAR.js:505:29)
	at Object.parseEnvFile (/Users/pedromelo/.vscode/extensions/ms-python.python-0.9.0/out/client/common/envFileParser.js:26:23)
	at Object.getCustomEnvVarsSync (/Users/pedromelo/.vscode/extensions/ms-python.python-0.9.0/out/client/common/utils.js:388:38)
	at JediProxy.spawnProcess (/Users/pedromelo/.vscode/extensions/ms-python.python-0.9.0/out/client/providers/jediProxy.js:214:51)
	at JediProxy.initialize (/Users/pedromelo/.vscode/extensions/ms-python.python-0.9.0/out/client/providers/jediProxy.js:177:14)
	at new JediProxy (/Users/pedromelo/.vscode/extensions/ms-python.python-0.9.0/out/client/providers/jediProxy.js:133:14)
	at JediFactory.getJediProxyHandler (/Users/pedromelo/.vscode/extensions/ms-python.python-0.9.0/out/client/languageServices/jediProxyFactory.js:27:31)
t.log @ console.ts:123
2console.ts:123 [Extension Host] Python Extension: documentHasJupyterCodeCells.promises Error: EISDIR: illegal operation on a directory, read
t.log @ console.ts:123
4console.ts:123 [Extension Host] Failed to parse env file Error: EISDIR: illegal operation on a directory, read
	at Object.fs.readSync (fs.js:682:19)
	at tryReadSync (fs.js:480:20)
	at Object.fs.readFileSync (fs.js:517:19)
	at Object.exports.wrapFsWithAsar.fs.readFileSync (ELECTRON_ASAR.js:505:29)
	at Object.parseEnvFile (/Users/pedromelo/.vscode/extensions/ms-python.python-0.9.0/out/client/common/envFileParser.js:26:23)
	at /Users/pedromelo/.vscode/extensions/ms-python.python-0.9.0/out/client/common/utils.js:366:42
	at Generator.next (<anonymous>)
	at fulfilled (/Users/pedromelo/.vscode/extensions/ms-python.python-0.9.0/out/client/common/utils.js:4:58)
	at <anonymous>
t.log @ console.ts:123
2console.ts:123 [Extension Host] Python Extension: documentHasJupyterCodeCells.promises Error: EISDIR: illegal operation on a directory, read
t.log @ console.ts:123
2console.ts:123 [Extension Host] rejected promise not handled within 1 second
t.log @ console.ts:123
log.ts:165   ERR EISDIR: illegal operation on a directory, read: Error: EISDIR: illegal operation on a directory, read
2console.ts:123 [Extension Host] rejected promise not handled within 1 second
t.log @ console.ts:123
2console.ts:123 [Extension Host] Python Extension: documentHasJupyterCodeCells.promises Error: EISDIR: illegal operation on a directory, read
t.log @ console.ts:123
console.ts:123 [Extension Host] rejected promise not handled within 1 second
t.log @ console.ts:123
log.ts:165   ERR EISDIR: illegal operation on a directory, read: Error: EISDIR: illegal operation on a directory, read
2console.ts:123 [Extension Host] rejected promise not handled within 1 second
t.log @ console.ts:123
console.ts:123 [Extension Host] (node:1596) DeprecationWarning: os.tmpDir() is deprecated. Use os.tmpdir() instead.
t.log @ console.ts:123

Issue Analytics

  • State:closed
  • Created 6 years ago
  • Reactions:3
  • Comments:12

github_iconTop GitHub Comments

16reactions
DonJayamannecommented, Dec 15, 2017
  • Do you have a directory named .env in your workspace?
  • Please could you try the following, create an empty file named .envFile in your workspace and add the following into your workspace settings settings.json:
"python.envFile": "${workspaceFolder}/.envFile"
2reactions
pscelzamelocommented, Dec 15, 2017

Happy for that! Thank you very much!

Read more comments on GitHub >

github_iconTop Results From Across the Web

NPM stuck giving the same error EISDIR: Illegal operation on ...
This means that NPM is trying to do something to a file but it is a directory. In your case, NPM is trying...
Read more >
cypress-io/cypress - Gitter
ERROR: Failed to merge reports. [Error: EISDIR: illegal operation on a directory, read] { errno: -21, code: 'EISDIR', syscall: 'read' }'. Joël Grimberg....
Read more >
Arduino CLI And IDE now Released - Teensy Supported!
PID: 19108 Using browser-only version of superagent in non-browser environment Error: EISDIR: illegal operation on a directory, ...
Read more >
Solved: Database failed to create: Error: EISDIR: illegal
Database failed to create: Error: EISDIR: illegal operation on a directory, open 'C:\Users\mblack\.
Read more >
How to Secure Your Elastic Stack (Plus Kibana, Logstash and ...
Of course, we always imagine the components are in a secure channel — the nodes of the cluster, the information shipping to them...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found