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.

Unable to start robotframework-lsp because: python could not be found on the PATH.

See original GitHub issue

I’m using the latest version of VS Code plugin (v0.38.1) and with this version appears the following error when try to start the language server:

Unable to start robotframework-lsp because: python could not be found on the PATH

I was looking for some difference in the latest version and I found this commit: https://github.com/robocorp/robotframework-lsp/commit/fb2d9bc0611a288270bdd47a9863965e37ba1ad6#diff-0fefade1994682e75a371a5e87217db562299ade61d20c91b09e427110ceb17e

For some reason the integration between this extension and vscode-python extension doesn’t work well for me, I don’t know if this issue happens because I’m using asdf-vm to manage my python versions.

The following line set executable with the full path of the python executable. (e.g. /Users/MyUser/.asdf/shims/python3.10)

executable = await (0, pythonExtIntegration_1.getPythonExtensionExecutable)()

The function findExecutableInPath(executable) wait for an executable and doesn’t for the full path.

WORKAROUND: just remove the code from the mentioned commit.

Issue Analytics

  • State:closed
  • Created 2 years ago
  • Comments:9

github_iconTop GitHub Comments

1reaction
andreagubellinicommented, Feb 1, 2022

@fabioz I confirm: the fix works fine.

0reactions
andreagubellinicommented, Feb 1, 2022

thanks I’ll try the fix and let you know

Read more comments on GitHub >

github_iconTop Results From Across the Web

PyCharm with LSP - Robot Framework
As alternative you could use the path to python executable in Path field and -u <path to repo>/src/robotframework_ls in the Args field.
Read more >
VS Code doesn't have the correct environment after creating a ...
Error in "import robot". It seems that Robot Framework is not installed in C:\Users\xxxxx\scoop\apps\python\current\python.exe.
Read more >
VSCode new Create Robot Project can't find Python Keywords
Starting RobotFramework Language Server with args: C:\Users\burrk\AppData\Local\robocorp\live\2aa1db4bb1a50e5e\python.exe,-u,c:\Users\burrk\.
Read more >
python - Robot Framework Language Server. Please update ...
I am just starting with the setup in MS Visual Studio Code and downloaded the python and robot framework language server extensions.
Read more >
robotframework-lsp 1.7.3 - PyPI
After having Robot Framework Language Server installed, some configurations (such as specifying the python executable used for launching the Language Server or ...
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