Saturday, May 15, 2010

How to start python IDLE in virtualenv on Windows

IDLE is an integrated development environment for Python. It is more convenient than plain python command prompt. In order to start IDLE in virtualenv environment you have to:
  • Copy tcl directory from your python installation folder to your environment directory.
  • Create shortcut with name IDLE to pythonw.exe that is located in Scripts directory of your environment.
  • Append "%PYTHON_HOME%\Lib\idlelib\idle.pyw" to the shortcut Target.
Once you are done you should be able start IDLE from within your environment.

4 comments :

  1. Great! Thanks for your contribution

    ReplyDelete
  2. Thanks for that post. The only one I could find. I am using Python 3.6 with Surface Windows 10. To get it to work I also had to copy the idlelib into the lib directory of the environment directory from the installation lib directory. Then point the shortcut to idle.pyw (from environment dirctory\Lib\idlelib\idle.pyw

    ReplyDelete
  3. Thanks for your solution. I am using Windows 10 (Surface 4 Pro) and Python 3.6. For me to make it work I also had to copy the idlelib directory into the Lib directory of the virtualenv.

    ReplyDelete