You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Describe the bug
When I create a new project with the Robot Framework Language Server plugin in Pycharm, there is an error that It seems that Robot Framework is not installed.
To Reproduce
Steps to reproduce the behavior:
Robot Framework Language Server plugin installed
Create a new empty pycharm project
a. Select new environment using Virtualenv
b. Location is project root directory: /Users/bayank/PycharmProjects/robot_demo/venv
c. Base Interpreter: using Homebrew python installation: /opt/homebrew/bin/python3
In the pycharm integrated terminal (venv is activated):
a. 'which python' returns '/Users/bayank/PycharmProjects/robot_demo/venv/bin/python
'
Create a new .robot file and create the first line '*** Settings ***' and shortly after the ide error is visible saying Robot is not installed in some other directory that looks like its my system python that I never touch. I'm using venv for every python project.
Error in "import robot". It seems that Robot Framework is not installed in /Applications/Xcode.app/Contents/Developer/usr/bin/python3. 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: /Applications/Xcode.app/Contents/Developer/usr/bin/python3 -m pip install robotframework
Also when I try to run the test I get this error
Error importing robot.
Python executable: /Applications/Xcode.app/Contents/Developer/usr/bin/python3.
Traceback (most recent call last):
File "/Users/bayank/Library/Application Support/JetBrains/PyCharm2023.2/plugins/robotframework-intellij/lib/robotframework_debug_adapter/run_robot__main__.py", line 673, in <module>
main()
File "/Users/bayank/Library/Application Support/JetBrains/PyCharm2023.2/plugins/robotframework-intellij/lib/robotframework_debug_adapter/run_robot__main__.py", line 650, in main
import robot
ModuleNotFoundError: No module named 'robot'
Robot Run Terminated (code: 0)
Expected behavior
The plugin should be aware of the venv im using and have activated and point to the venv python executable.
Recovery
Manually set the Language Server Python option in the plugin settings to the project venv python executable. In my case it's '/Users/bayank/PycharmProjects/robot_demo/venv/bin/python'
I was unable to get logs because there is an error in the plugin settings when I attempt to set the environment variable while following the steps in the linked doc:
The text was updated successfully, but these errors were encountered:
bayank
changed the title
Pycharm Language server plugin is not using the venv python executable. Looking for robot in the system python installation.
Pycharm Language server plugin is not using the venv python executable. It seems that Robot Framework is not installed.
Dec 9, 2023
Describe the bug
When I create a new project with the Robot Framework Language Server plugin in Pycharm, there is an error that It seems that Robot Framework is not installed.
To Reproduce
Steps to reproduce the behavior:
Robot Framework Language Server plugin installed
Create a new empty pycharm project
a. Select new environment using Virtualenv
b. Location is project root directory: /Users/bayank/PycharmProjects/robot_demo/venv
c. Base Interpreter: using Homebrew python installation: /opt/homebrew/bin/python3
In the pycharm integrated terminal (venv is activated):
a. 'which python' returns '/Users/bayank/PycharmProjects/robot_demo/venv/bin/python
'
'pip install robotframework'
a: 'which robot' returns '/Users/bayank/PycharmProjects/robot_demo/venv/bin/robot'
Create a new .robot file and create the first line '*** Settings ***' and shortly after the ide error is visible saying Robot is not installed in some other directory that looks like its my system python that I never touch. I'm using venv for every python project.
Error in "import robot". It seems that Robot Framework is not installed in /Applications/Xcode.app/Contents/Developer/usr/bin/python3. 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: /Applications/Xcode.app/Contents/Developer/usr/bin/python3 -m pip install robotframework
Expected behavior
The plugin should be aware of the venv im using and have activated and point to the venv python executable.
Recovery
Screenshots
Versions:
Logs
Add the logs obtained when reproducing the issue.
See: https://github.com/robocorp/robotframework-lsp/blob/master/robotframework-ls/docs/reporting_issues.md for details on how to collect the logs.
I was unable to get logs because there is an error in the plugin settings when I attempt to set the environment variable while following the steps in the linked doc:
The text was updated successfully, but these errors were encountered: