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.

VS Code doesn't have the correct environment after creating a robot template, autocompletion doesn't work

See original GitHub issue

Describe the bug After creating a new Robot, the development environment isn’t set up correctly.

Error in "import robot".
It seems that Robot Framework is not installed in C:\Users\xxxxx\scoop\apps\python\current\python.exe.
Please install it in your environment and restart the Robot Framework Language Server
or set: "robot.language-server.python" or "robot.python.executable"
to point to a python installation that has Robot Framework installed.
Hint: with pip it can be installed with:
C:\Users\xxxxx\scoop\apps\python\current\python.exe -m pip install robotframework

No keyword autocompletion, no “Load in Interactive Console” appears in the editor.

To Reproduce Steps to reproduce the behavior:

  1. Install Robocorp Code and Robotframework Language Server extensions for VS Code
  2. Robocorp: Create Robot
  3. Standard Robot Framework template
  4. Use workspace folder

Expected behavior Automatical creation of a environment with robotframework installed. If the robot contains conda.yaml file, the environment is created according to the config given. Where is this environment, why isn’t the environment selected for vs code?

Versions:

  • OS: Windows 10
  • Robocorp Code Version: 0.27.1
  • Robot Framework Language Server Version: 0.40.1
  • Client Version: VSCode 1.64.2

Issue Analytics

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

github_iconTop GitHub Comments

1reaction
fabiozcommented, Mar 10, 2022

This is now fixed.

As a note, it’s available in a pre-release if you want to check it (see: https://code.visualstudio.com/updates/v1_63#_pre-release-extensions on how to use pre-releases).

1reaction
vincentmathiscommented, Feb 24, 2022

I can confirm that uninstalling python3 resolved the issue. I only had it for some backward compability in another project so just uninstalling it is fine for now.

Read more comments on GitHub >

github_iconTop Results From Across the Web

Tab autocomplete in Visual Studio Code doesn't work
editor.tabCompletion was off. When I turn it on it toggles between some options (e.g. div/device) but doesn't close tags or complete anything.
Read more >
Configuration of VSCode (launch.json) - Robot Framework
If everything is installed correctly, you can load your project, press F1 and type “Python Select interpreter” to select the correct python ...
Read more >
Unable to run Robot Framework from VS Code ... - YouTube
Watch this video if:1) You are not able to see run option for the Robot test case in VS Code2) You are getting...
Read more >
pandas not working in vscode - You.com | The AI Search ...
I had the same issue. The problem was that VS Code was using a different environment (shown in the lower left corner). Switching...
Read more >
Setting python development environment Isaac Sim
I have set everything and run the examples and I even manage to load my robot (UR3e) from URDF and fix everything to...
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