mxsdev / nvim-dap-vscode-js

nvim-dap adapter for vscode-js-debug
287 stars 30 forks source link

Reserved `NODE_PATH` is used in this project #30

Open qRoC opened 1 year ago

qRoC commented 1 year ago

NODE_PATH is reserved env variable (https://nodejs.org/api/modules.html)

mbarneyjr commented 6 months ago

I just hit this issue too.

NODE_PATH is an environment variable that's meant to point to a node_modules directory that a node process will be able to import from. This environment variable is not meant to point to a node executable. This environment variable is set on my machine to a node_modules directory, which means that this plugin tries to execute that directory, and fails to do so, leaving the following error message:

‼ ERROR [dap-js] Error trying to launch JS debugger: EACCES: permission denied

mbarneyjr commented 6 months ago

The quick workaround is to set node_path on this plugin's config as setup time, but I think a different default environment variable should be used