Snap VsCode Ubuntu / Julia Ubuntu Store 版本中的 Julia 二进制设置错误

Koo*_*ops 4 ubuntu julia visual-studio-code

背景:

您通过 Ubuntu Store / Snap Store 安装了 Julia,并且正在使用 VS Code 进行编码。当您下载必要的扩展时,您会看到一个弹出窗口,显示:

Could not start the Julia language server. Make sure the configuration setting julia.executablePath points to the Julia binary.
Run Code Online (Sandbox Code Playgroud)

经过一番挖掘,我找到了一些关于这个问题的解决方案!

Koo*_*ops 6

这不是一个问题,而是 VS Code 在处理从 Ubuntu Store/Snap 下载的 Julia lang 时引发的问题/错误的答案。错误信息如下:

Could not start the Julia language server. Make sure the configuration setting julia.executablePath points to the Julia binary.

要解决此问题,您必须指向Julia BinaryJulia 可执行应用程序。您的问题的可能解决方案可能是:

首先将以下路径粘贴到您的 Julia 可执行路径。粘贴它并重新启动 VS Code。

/snap/julia/current/bin/julia
Run Code Online (Sandbox Code Playgroud)

在你的 settings.json 中你应该有以下内容。(仅当您通过 Ubuntu Store 下载 Julia 时才适用)

"julia.symbolCacheDownload": true,
"julia.enableTelemetry": false,
"julia.executablePath": "/snap/julia/current/bin/julia"
Run Code Online (Sandbox Code Playgroud)

如果这不起作用,请尝试以下操作:

  1. Julia在扩展市场中搜索

  2. 下载Julia并Julia Insider

  3. 您将收到一条错误消息,指出您不能同时安装两者(活动)

  4. 卸载Julia Insider

  5. 重新启动 VS 代码

  6. 通过创建文件扩展名 ( .jl ) j 的文件进行测试,如“(J)ulia” l,如“(L)anguage”

  7. CTRL用+执行F5

朱莉娅编码快乐!