-1

I am a beginner to coding in general and I just found out that we could create virtual environments and was soon disappointed to see that there was no tutorial or answer anywhere for a Windows user and the only one I found was THIS. Which kinda solves my problem but isn't ideal. And I wanted to follow forms that actually SOLVED my problem but they were for mac and linux users. So can someone help me out?

Thanks in advance !!!

1 Answers1

1

It is mentioned in the docs:

For virtualenv created environments to be discoverable by SublimeREPL they should be created or symlinked in one of the following:

  • ~/.virtualenvs default for virtualenvwrapper
  • ~/.venvs default for venv

Alternatively, more paths can be added to “python_virtualenv_paths” in the SublimeREPL configuration file.

If your virtualenvs are created in another directory add them to SublimeREPL.sublime-settings. For me, they are in ~/Envs:

{
    "python_virtualenv_paths": ["C:\\Users\\my_username\\Envs"]
}

Assuming you're using the correct path, sublimeREPL: Python - virtualenv allows you to select the venv you want to work with:

Maurice Meyer
  • 17,279
  • 4
  • 30
  • 47
  • thanks a lot, I have been able to load the virtual environment through the drop-down menu but when I run my file it shows an error that the selenium module doesn't exist but when I type it into the REPL it gives no error. – Shreyas Devesh Apr 06 '21 at 12:54
  • Probably you need [Virtualenv package](https://packagecontrol.io/packages/Virtualenv) additionally, to run scripts within a venv. – Maurice Meyer Apr 06 '21 at 12:58