On Mon, Oct 22, 2012 at 6:51 AM, anatoly techtonik <techtonik@gmail.com> wrote:
I wonder if it will make the life easier if Python was installed with .py association to "%PYTHON_HOME%\python.exe" "%1" %* It will remove the need to run .py scripts in virtualenv with explicit 'python' prefix.
Example how it doesn't work right now
E:\virtenv32\Scripts>echo import sys; print(sys.version) > test.py
E:\virtenv32\Scripts>test.py 3.3.0 (v3.3.0:bd8afb90ebf2, Sep 29 2012, 10:55:48) [MSC v.1600 32 bit (Intel)]
E:\virtenv32\Scripts>python test.py 3.2.3 (default, Apr 11 2012, 07:15:24) [MSC v.1500 32 bit (Intel)] If Python file association was specified with "%PYTHON_HOME%\python.exe" "%1" %* then virtualenv could override this variable when setting the environment to set correct executable for .py files.
I believe you can solve your problem with the PY_PYTHON environment variable or the user's py.ini file. See section 3.4.4 of the documentation.