VSCode cannot find the Julia executable that exists

Hi. I am trying to get my Julia 1.5.4 to work with my VSCode but it does not. I do not understand why this is the case. I renewed the installation for each but the problem persists. This is my Preferences > Settings > Julia: Executable Path:

This path does indeed exist. This is my settings.json:

{
    "[julia]": {

        "editor.quickSuggestions": true,
        "editor.wordSeparators": "`~#$%^&*()-=+[{]}\\|;:'\",.<>/?"
    },
    "julia.executablePath": "/home/onur/julia-1.5.4/bin/julia"
}

Again. The path does exist. But each time I try to run my example code, this is what I get:

How are you trying to run the code in that screenshot? I don’t think we ever try to run code in that task terminal thing?

Perhaps it is

.../julia 1.5.4/...

space instead of - ?

The triangular run button at the far right. That’s what I hit to run my code…

Hm. When you open the settings UI (as opposed to the json file) you should see a bunch of tabs at the top. Can you check whether you have set the executable path differently in any of those?

How is that different from the image in my original post?

What you show (assuming it’s under the “user” tab) might not be what VSCode is actually using – it might be overwritten by workspace or remote specific settings.

So how can I confirm that?

Hey there,

Maybe you can try the following:

  1. Check if you’re using the command prompt, or PowerShell shell as your default. Maybe your PS is blocked or something.
  2. Try adding the full path (In my case it looks like “julia.executablePath”: “C:\Users\MY_USER\AppData\Local\Programs\Julia-1.6.0\bin\julia.exe”)
  3. To confirm the above. You should be able to copy paste your path, and run it by hand on cmd.exe, and initiate a Julia terminal.

Best!

Hello.

I’m on Ubuntu 20.04 so none of those apply to me…

By checking the other possibilities.

I’d also recommend using the “Julia: Start REPL” command from the command palette, just to make sure no other extension accidentally hijacked the run button or whatnot.

I tried to use Julia from the command palette as you’ve suggested:

The terminal process failed to launch: Path to shell executable ""julia.executablePath": "/home/onur/julia-1.5.4/bin/julia"" does not exist.

Same exact error.

Can you provide the output of:

ls -la /home/onur/julia-1.5.4/bin/julia

in a bash shell?
I want to see prove that the path exist! :wink:

-rwxr-xr-x 1 onur onur 46192 Mar 11 14:25 /home/onur/julia-1.5.4/bin/julia

You still have the wrong path set somewhere. Make sure to check the JSON formatting as well – the error should show something like

The terminal process failed to launch: Path to shell executable "/this/does/not/exist" does not exist.

and not have any JSON like formatting.

Proof accepted :slight_smile:

In the erroe screenshot you have as path version 1.0.5 : /home/onur/julia-1.0.5/bin/julia
Any idea where this comes from?
Can we see bash output of

env | grep -i julia

It yields no output…

Here is my JSON:

{
    "[julia]": {

        "editor.quickSuggestions": true,
        "editor.wordSeparators": "`~#$%^&*()-=+[{]}\\|;:'\",.<>/?"
    },
    "julia.executablePath": "/home/onur/julia-1.5.4/bin/julia"
}

I hear you that it is definitely what is causing this error. But the path is correct both in my JSON file and the user settings. Where else could it be?

Did you check the workspace/remote/folder specific settings as mentioned above? Just to illustrate:
image