After successfully configure the virtual environment in Anaconda, you need to add the virtual environment to PyCharm. However, sometimes the conda executable is not found error occurs when selecting conda virtual environment. In this article, I will tell you how to fix this error.
1. How To Fix Conda Executable Is Not Found When Add Anaconda Virtual Environment In PyCharm.
- When adding an Anaconda virtual environment to PyCharm, you may encounter the error “conda executable not found“.
- This error occurs because PyCharm is unable to locate the conda executable on your system.
- To fix this error, you need to add the path to the conda executable to the system PATH environment variable.
- If you use Windows, you can open the System Properties window, and click on the Advanced tab.
- On the Advanced tab, click on the Environment Variables button.
- In the Environment Variables window, select the PATH variable, and click the Edit button.
- In the Edit System Variable window, add the path to the conda executable, and click OK.
- Now you need to select the conda executable file in PyCharm.
- First, open PyCharm, go to the Settings window, then go to the Project Interpreter section ( please refer to the article How To Install Python Interpreter In PyCharm ).
- Click the “Add..” button. In the drop-down, select the “Conda Environment” option.
- Click on the Browse button, and select the conda executable file (conda.exe) from the file explorer window.
- Once you have selected the correct file, click OK, and the conda executable file will be added to your Python interpreter.
- Click the Load Environments button to load the existing virtual environment from anaconda.
- Then select the “Use existing environment” option.
- You can then navigate to the folder where the conda executable file is located and select it.
- Finally, click the “OK” button to save the changes.