davidmarble / virtualenvwrapper-win Goto Github PK
View Code? Open in Web Editor NEWPort of Doug Hellmann's virtualenvwrapper to Windows batch scripts
License: Other
Port of Doug Hellmann's virtualenvwrapper to Windows batch scripts
License: Other
Since 1.1.6 behaviour of "workon" command changed so it CDs to virtualenv directory, if no "project_dir" set for virtualenv.
mkvirtualenv venv_name
setprojectdir path_to_project_dir
Quite often I'm already in desired directory for project and just had to type "workon venv" so I was activating venv in place where I needed it. Sometimes different "projects" using same venv
Now I have to make couple additional steps to CD in project dir. :\
It will be nice to cd in project dir if it is set up for venv or just stay in current dir if no project_dir preconfigured.
It would be nice to have a -p switch to be able to create a virtualenv with specific Python version, e.g.
mkvirtualenv -p 2.7 FOO_BAR
While I got the following error when installing (pip install virtualenvwrapper-win)...
...
writing dependency_links to virtualenvwrapper_win.egg-info\dependency_links.txt
warning: manifest_maker: standard file '-c' not found
reading manifest file 'virtualenvwrapper_win.egg-info\SOURCES.txt'
reading manifest template 'MANIFEST.in'
writing manifest file 'virtualenvwrapper_win.egg-info\SOURCES.txt'
error: [Error 183] Impossible de crΘer un fichier dΘjα existant: 'build\\bdist.win32\\wheel\\virtualenvwrapper_win-1.2.1.data\\..'
----------------------------------------
Failed building wheel for virtualenvwrapper-win
Failed to build virtualenvwrapper-win
Installing collected packages: virtualenv, virtualenvwrapper-win
Running setup.py install for virtualenvwrapper-win
Successfully installed virtualenv-13.1.2 virtualenvwrapper-win-1.2.1
... *.bat files just installed successfully.
This failure message is puzzling. What do wheels or eggs have to see with installation of *.bat files ?
Environment : pip 7.0.1 from C:\Python27\lib\site-packages (python 2.7)
It looks like there isn't a way to switch access to the global site-packages directory on or off after you've created your virtualenv. This is useful for debugging configs. Would it possible add this as an additional Windows command? See http://www.doughellmann.com/docs/virtualenvwrapper/command_ref.html#toggleglobalsitepackages.
When mkvirtualenv command, how to set Python ver?
I've downloaded and installed virtualenvwrapper-win on a Windows 7 box and have been trying to use it with Django. The problem seems to be around trying to call the command django-admin.py startproject foo. After some research, it seems like one of the problems is that with windows you still have the project with .py files begin associated with a hardcoded command in the windows registry. For me, this is in HKEY_CLASSES_ROOT\Python.File\shell\open\command. I've seen some suggestions out there to try add to the activate script a command to change the ftype Python.File = , however, I have not been able to make that work with (or without) virtualenvwrapper-win. The easiest way to reproduce this problem is to follow the tutorial on Heroku. https://devcenter.heroku.com/articles/django
I'm testing on XP (home), and it works just fine... but if you don't set up a custom WORKON_HOME, mkvirtualenv and friends will complain... that's essentially because the %USERPROFILE% part in the default WORKON_HOME has spaces in it (c:/Documents and Settings/etc/etc).
So I had to set up my custom WORKON_HOME to a dir with no spaces, and it just worked.
One thing I've noticed in this and another Windows port is that after you say "workon [environment]" one or two times, the tab completion of possible environment names dies. Is that just an issue with Windows or is it something that can be corrected? If so, can you point me at where the issue lies? I'm really happy with this project and would like to give back.
Hello,
I have used virtualenvwrapper under Linux for quite a while and I'm pleased to find this great port for Windows!
While I experimented with it, I noticed a small issue, which could lead to LOSS of data sometimes (running rmvirtualenv).
Scenario is as follows:
This is due to not specifying the "/d" argument to CD when switching to the virtualenv dir, thus remaining on the same drive, rather than switching the drive as well.
I prepared a patch to solve this issue: virtualenvwrapper-win-cd_drive.patch
Best regards and keep the good work!
dimitern
Fantastic job on the port to windows cmd scripts.
I'm running windows7 x64 and python 2.6.8.
When using add2virtualenv X:/path/to/site, add2virtualenv.bat appends the following:
"X:\path\to\site"
The included double quotes surrounding the path prevents the path from being recognized as another site directory. Everything else seems to be running quite smoothly. Thanks so much for the port!
I have a fresh python 2.7.5 installation, setuptools 0.7.2, and pip (latest). I'm unable to install using either pip or easy_install.
C:\Users\rsyring\Desktop>pip install virtualenvwrapper-win
Downloading/unpacking virtualenvwrapper-win
Downloading virtualenvwrapper-win-1.1.4.zip
Running setup.py egg_info for package virtualenvwrapper-win
Downloading http://pypi.python.org/packages/source/d/distribute/distribute-0
.6.35.tar.gz
Extracting in c:\users\rsyring\appdata\local\temp\tmpq5vt15
Now working in c:\users\rsyring\appdata\local\temp\tmpq5vt15\distribute-0.6.
35
Building a Distribute egg in c:\users\rsyring\appdata\local\temp\pip-build-r
syring\virtualenvwrapper-win
Traceback (most recent call last):
File "setup.py", line 45, in <module>
exec(init_file.read(), d)
File "<string>", line 8, in <module>
File "c:\users\rsyring\appdata\local\temp\tmpq5vt15\distribute-0.6.35\setu
ptools\__init__.py", line 2, in <module>
from setuptools.extension import Extension, Library
File "c:\users\rsyring\appdata\local\temp\tmpq5vt15\distribute-0.6.35\setu
ptools\extension.py", line 5, in <module>
from setuptools.dist import _get_unpatched
File "c:\users\rsyring\appdata\local\temp\tmpq5vt15\distribute-0.6.35\setu
ptools\dist.py", line 6, in <module>
from setuptools.command.install import install
File "c:\users\rsyring\appdata\local\temp\tmpq5vt15\distribute-0.6.35\setu
ptools\command\__init__.py", line 8, in <module>
from setuptools.command import install_scripts
File "c:\users\rsyring\appdata\local\temp\tmpq5vt15\distribute-0.6.35\setu
ptools\command\install_scripts.py", line 3, in <module>
from pkg_resources import Distribution, PathMetadata, ensure_directory
File "c:\users\rsyring\appdata\local\temp\tmpq5vt15\distribute-0.6.35\pkg_
resources.py", line 2825, in <module>
add_activation_listener(lambda dist: dist.activate())
File "c:\users\rsyring\appdata\local\temp\tmpq5vt15\distribute-0.6.35\pkg_
resources.py", line 710, in subscribe
callback(dist)
File "c:\users\rsyring\appdata\local\temp\tmpq5vt15\distribute-0.6.35\pkg_
resources.py", line 2825, in <lambda>
add_activation_listener(lambda dist: dist.activate())
File "c:\users\rsyring\appdata\local\temp\tmpq5vt15\distribute-0.6.35\pkg_
resources.py", line 2257, in activate
self.insert_on(path)
File "c:\users\rsyring\appdata\local\temp\tmpq5vt15\distribute-0.6.35\pkg_
resources.py", line 2358, in insert_on
"with distribute. Found one at %s" % str(self.location))
ValueError: A 0.7-series setuptools cannot be installed with distribute. Fou
nd one at c:\python27\lib\site-packages\setuptools-0.7.2-py2.7.egg
c:\users\rsyring\appdata\local\temp\pip-build-rsyring\virtualenvwrapper-win\
distribute-0.6.35-py2.7.egg
Traceback (most recent call last):
File "<string>", line 16, in <module>
File "c:\users\rsyring\appdata\local\temp\pip-build-rsyring\virtualenvwrap
per-win\setup.py", line 4, in <module>
use_setuptools()
File "distribute_setup.py", line 152, in use_setuptools
return _do_download(version, download_base, to_dir, download_delay)
File "distribute_setup.py", line 132, in _do_download
_build_egg(egg, tarball, to_dir)
File "distribute_setup.py", line 123, in _build_egg
raise IOError('Could not build the egg.')
IOError: Could not build the egg.
Complete output from command python setup.py egg_info:
Downloading http://pypi.python.org/packages/source/d/distribute/distribute-0
.6.35.tar.gz
Extracting in c:\users\rsyring\appdata\local\temp\tmpq5vt15
Now working in c:\users\rsyring\appdata\local\temp\tmpq5vt15\distribute-0.6.35
Building a Distribute egg in c:\users\rsyring\appdata\local\temp\pip-build-rsyri
ng\virtualenvwrapper-win
Traceback (most recent call last):
File "setup.py", line 45, in <module>
exec(init_file.read(), d)
File "<string>", line 8, in <module>
File "c:\users\rsyring\appdata\local\temp\tmpq5vt15\distribute-0.6.35\setuptoo
ls\__init__.py", line 2, in <module>
from setuptools.extension import Extension, Library
File "c:\users\rsyring\appdata\local\temp\tmpq5vt15\distribute-0.6.35\setuptoo
ls\extension.py", line 5, in <module>
from setuptools.dist import _get_unpatched
File "c:\users\rsyring\appdata\local\temp\tmpq5vt15\distribute-0.6.35\setuptoo
ls\dist.py", line 6, in <module>
from setuptools.command.install import install
File "c:\users\rsyring\appdata\local\temp\tmpq5vt15\distribute-0.6.35\setuptoo
ls\command\__init__.py", line 8, in <module>
from setuptools.command import install_scripts
File "c:\users\rsyring\appdata\local\temp\tmpq5vt15\distribute-0.6.35\setuptoo
ls\command\install_scripts.py", line 3, in <module>
from pkg_resources import Distribution, PathMetadata, ensure_directory
File "c:\users\rsyring\appdata\local\temp\tmpq5vt15\distribute-0.6.35\pkg_reso
urces.py", line 2825, in <module>
add_activation_listener(lambda dist: dist.activate())
File "c:\users\rsyring\appdata\local\temp\tmpq5vt15\distribute-0.6.35\pkg_reso
urces.py", line 710, in subscribe
callback(dist)
File "c:\users\rsyring\appdata\local\temp\tmpq5vt15\distribute-0.6.35\pkg_reso
urces.py", line 2825, in <lambda>
add_activation_listener(lambda dist: dist.activate())
File "c:\users\rsyring\appdata\local\temp\tmpq5vt15\distribute-0.6.35\pkg_reso
urces.py", line 2257, in activate
self.insert_on(path)
File "c:\users\rsyring\appdata\local\temp\tmpq5vt15\distribute-0.6.35\pkg_reso
urces.py", line 2358, in insert_on
"with distribute. Found one at %s" % str(self.location))
ValueError: A 0.7-series setuptools cannot be installed with distribute. Found o
ne at c:\python27\lib\site-packages\setuptools-0.7.2-py2.7.egg
c:\users\rsyring\appdata\local\temp\pip-build-rsyring\virtualenvwrapper-win\dist
ribute-0.6.35-py2.7.egg
Traceback (most recent call last):
File "<string>", line 16, in <module>
File "c:\users\rsyring\appdata\local\temp\pip-build-rsyring\virtualenvwrapper-
win\setup.py", line 4, in <module>
use_setuptools()
File "distribute_setup.py", line 152, in use_setuptools
return _do_download(version, download_base, to_dir, download_delay)
File "distribute_setup.py", line 132, in _do_download
_build_egg(egg, tarball, to_dir)
File "distribute_setup.py", line 123, in _build_egg
raise IOError('Could not build the egg.')
IOError: Could not build the egg.
----------------------------------------
Command python setup.py egg_info failed with error code 1 in c:\users\rsyring\ap
pdata\local\temp\pip-build-rsyring\virtualenvwrapper-win
Storing complete log in C:\Users\rsyring\pip\pip.log
C:\Users\rsyring\Desktop>easy_install virtualenvwrapper-win
Searching for virtualenvwrapper-win
Reading https://pypi.python.org/simple/virtualenvwrapper-win/
Reading https://github.com/davidmarble/virtualenvwrapper-win/
Best match: virtualenvwrapper-win 1.1.4
Downloading https://pypi.python.org/packages/source/v/virtualenvwrapper-win/virt
ualenvwrapper-win-1.1.4.zip#md5=b28bddb9262c767eec6ee17534f20fc1
Processing virtualenvwrapper-win-1.1.4.zip
Writing c:\users\rsyring\appdata\local\temp\easy_install-a_tymt\virtualenvwrappe
r-win-1.1.4\setup.cfg
Running virtualenvwrapper-win-1.1.4\setup.py -q bdist_egg --dist-dir c:\users\rs
yring\appdata\local\temp\easy_install-a_tymt\virtualenvwrapper-win-1.1.4\egg-dis
t-tmp-dlddsg
Downloading http://pypi.python.org/packages/source/d/distribute/distribute-0.6.3
5.tar.gz
Extracting in c:\users\rsyring\appdata\local\temp\easy_install-a_tymt\virtualenv
wrapper-win-1.1.4\temp\tmpbf532g
Now working in c:\users\rsyring\appdata\local\temp\easy_install-a_tymt\virtualen
vwrapper-win-1.1.4\temp\tmpbf532g\distribute-0.6.35
Building a Distribute egg in c:\users\rsyring\appdata\local\temp\easy_install-a_
tymt\virtualenvwrapper-win-1.1.4
Traceback (most recent call last):
File "setup.py", line 45, in <module>
exec(init_file.read(), d)
File "<string>", line 8, in <module>
File "c:\users\rsyring\appdata\local\temp\easy_install-a_tymt\virtualenvwrappe
r-win-1.1.4\temp\tmpbf532g\distribute-0.6.35\setuptools\__init__.py", line 2, in
<module>
from setuptools.extension import Extension, Library
File "c:\users\rsyring\appdata\local\temp\easy_install-a_tymt\virtualenvwrappe
r-win-1.1.4\temp\tmpbf532g\distribute-0.6.35\setuptools\extension.py", line 5, i
n <module>
from setuptools.dist import _get_unpatched
File "c:\users\rsyring\appdata\local\temp\easy_install-a_tymt\virtualenvwrappe
r-win-1.1.4\temp\tmpbf532g\distribute-0.6.35\setuptools\dist.py", line 6, in <mo
dule>
from setuptools.command.install import install
File "c:\users\rsyring\appdata\local\temp\easy_install-a_tymt\virtualenvwrappe
r-win-1.1.4\temp\tmpbf532g\distribute-0.6.35\setuptools\command\__init__.py", li
ne 8, in <module>
from setuptools.command import install_scripts
File "c:\users\rsyring\appdata\local\temp\easy_install-a_tymt\virtualenvwrappe
r-win-1.1.4\temp\tmpbf532g\distribute-0.6.35\setuptools\command\install_scripts.
py", line 3, in <module>
from pkg_resources import Distribution, PathMetadata, ensure_directory
File "c:\users\rsyring\appdata\local\temp\easy_install-a_tymt\virtualenvwrappe
r-win-1.1.4\temp\tmpbf532g\distribute-0.6.35\pkg_resources.py", line 2825, in <m
odule>
add_activation_listener(lambda dist: dist.activate())
File "c:\users\rsyring\appdata\local\temp\easy_install-a_tymt\virtualenvwrappe
r-win-1.1.4\temp\tmpbf532g\distribute-0.6.35\pkg_resources.py", line 710, in sub
scribe
callback(dist)
File "c:\users\rsyring\appdata\local\temp\easy_install-a_tymt\virtualenvwrappe
r-win-1.1.4\temp\tmpbf532g\distribute-0.6.35\pkg_resources.py", line 2825, in <l
ambda>
add_activation_listener(lambda dist: dist.activate())
File "c:\users\rsyring\appdata\local\temp\easy_install-a_tymt\virtualenvwrappe
r-win-1.1.4\temp\tmpbf532g\distribute-0.6.35\pkg_resources.py", line 2257, in ac
tivate
self.insert_on(path)
File "c:\users\rsyring\appdata\local\temp\easy_install-a_tymt\virtualenvwrappe
r-win-1.1.4\temp\tmpbf532g\distribute-0.6.35\pkg_resources.py", line 2358, in in
sert_on
"with distribute. Found one at %s" % str(self.location))
ValueError: A 0.7-series setuptools cannot be installed with distribute. Found o
ne at c:\python27\lib\site-packages\setuptools-0.7.2-py2.7.egg
c:\users\rsyring\appdata\local\temp\easy_install-a_tymt\virtualenvwrapper-win-1.
1.4\distribute-0.6.35-py2.7.egg
error: None
virtualenvwrapper-win requires virtualenv==1.9.1, which doesn't work on python 3.4:
C:\Users\dpantele\temp>virtualenv temp_test
Using base prefix 'C:\\Python34'
New python executable in temp_test\Scripts\python.exe
Failed to import the site module
Traceback (most recent call last):
File "C:\Users\dpantele\temp\temp_test\lib\site.py", line 67, in <module>
import os
File "C:\Users\dpantele\temp\temp_test\lib\os.py", line 634, in <module>
from _collections_abc import MutableMapping
ImportError: No module named '_collections_abc'
ERROR: The executable temp_test\Scripts\python.exe is not functioning
ERROR: It thinks sys.prefix is 'c:\\users\\dpantele\\temp' (should be 'c:\\users
\\dpantele\\temp\\temp_test')
ERROR: virtualenv is not compatible with this system or executable
Note: some Windows users have reported this error when they installed Python for
"Only this user" or have multiple versions of Python installed. Copying the app
ropriate PythonXX.dll to the virtualenv Scripts/ directory may fix this problem.
virtualenvwrapper
implements a mkproject
command which creates a project dir, creates an environment variable, and connects them with it's equivalent of setproject
.
This is a nice shortcut, and virtualenvwrapper-win
should have it.
Programs:
terminal: cmd
python: python2.7
virtualenvwrapper-win: pip install virtualenvwrapper-win
Error:
Microsoft Windows [Versión 6.1.7600]
Copyright (c) 2009 Microsoft Corporation. Reservados todos los derechos.
C:\Users\Usuario>pyassoc
.py files will launch with "~0,-1\Scripts\python.bat" "%1" %*
C:\Users\Usuario>mkvirtualenv test
INFORMACION: no se pudo encontrar ningún archivo para los patrones dados.
El sistema no puede encontrar la ruta especificada. (The system cannot found the specified path)
El sistema no puede encontrar la ruta especificada.
El sistema no puede encontrar la ruta especificada.
C:\Users\Usuario>path
PATH=C:\Program Files\Common Files\Microsoft Shared\Windows Live;C:\Windows\syst
em32;C:\Windows;C:\Windows\System32\Wbem;C:\Windows\System32\WindowsPowerShell\v
1.0;C:\Python27\Scripts;C:\Program Files\TortoiseHg;C:\Program Files\Mercurial
When I run this, it seems to install the scripts into C:\python27, rather than c:\python27\scripts. That's a problem going forward for those of us using the Python launcher (e.g., see http://testerstories.com/2014/06/multiple-versions-of-python-on-windows/) because that pattern requires keeping the Python directories out of the path.
I was just wondering -- is the the cpvirtualenv
command not implemented in virtualenvwrapper-win
? If not, what would be the best workaround for renaming a virtualenv?
Thanks!
mkvirtualenv.bat wasn't working for me till I have modified a path in its code.
I'm Using:
Windows 10 Build 10130 x64
python 3.4.3
pip 7.0.1
setuptools 12.0.5
virtualenv 13.0.1
virtualenv-clone 0.2.5
virtualenwrapper 4.5.1
virtualenvwrapper-win 1.2.0
Default UAC Settings.
My %PATH% (not modified manually):
C:\Python34;C:\Python34\Scripts;%SystemRoot%\system32;%SystemRoot%;%SystemRoot%\System32\Wbem;%SYSTEMROOT%\System32\WindowsPowerShell\v1.0;C:\Program Files\nodejs;C:\Program Files (x86)\Skype\Phone;C:\Program Files (x86)\Git\cmd
My %WORKON_HOME%:
C:\virtualenvs
My %PYHOME%:
C:\Python34\
I have modified the else path part (lines 49 to 53) of mkvirtualenv.bat:
if exist "%PYHOME%\Scripts\virtualenv-script.py" (
python.exe "%PYHOME%\Scripts\virtualenv-script.py" %ARGS%
) else (
#From "virtualenv.exe %ARGS%" (without quotes) to:
python.exe "%PYHOME%\Scripts\virtualenv.exe" %ARGS%
)
My *.bat
scripts was installed in my base prefix, C:\python34
and not in C:\python34\
And this is why it wasn't working.
I don't know If this is just a workaround or the way to go. But a point, de documentation says to setup %PATH%
and %WORKON_HOME%
, but the code uses %PYHOME%
Shouldn't be the code be using one or the other but not both env vars ? :$
I also think that's very ugly the python.exe "%PYHOME%\Scripts\virtualenv.exe" %ARGS%
call. Calling an exe from another exe xd But this is my fault Hehe
workon, deactivate, rmvirtualenv & lsvirtualenv commands work fine after this change.
The Unix version of virtualenvwrapper works with pyvenv and does not install virtualenv. I don't really understand why the same approach couldn't work for virtualenvwrapper-win? (In fact, if I subsequently run pip uninstall virtualenv, virtualenvwrapper-win appears to keep working as expected.)
In dhellmann's mkvirtualenv, he passes on options like --distribute and --no-site-packages. These are not propagating in this Windows port.
I'm trying to use PyPy as my Python implementation of choice, but I'm having some issues. It looks like the batch files are using ENV\Scripts, but for some reason PyPy (and virtualenv under PyPy?) likes to use ENV\bin instead. Is there a way to check for existence of Scripts, then bin, and prefer that order?
assoc.exe & ftype.exe use HKCR to update and query. This translates to HKLM which requires admin privileges.
The following utility may be more suitable as it can work with HKCU. working D/L link.
Hi David,
I was trying to associate a project with a venv and got the following error:
mkvirtualenv -a c:\pcode\joshim testenv
The system cannot find the path specified.
The system cannot find the path specified.
The system cannot find the path specified.
Then I ran where python.exe and get the foll output:
c:\python27\python.exe
If I try to create a venv without associating a project folder to it, then it works fine.
I'm running Win 7 Pro, Python 2.7
Thanks for your help.
I am following up on #27 and am still not able to inherit global site packages in a new virtualenv on windows. I have done a fresh install of pip (1.3.1), distribute (0.6.35), virtualenv (1.9.1), and virtualenvwrapper-win (1.1.3). I still do not see any visible difference in packages before and after toggling the global site package status:
C:\Dropbox\Code>mkvirtualenv toggletest
PYTHONHOME is set. You *must* activate the virtualenv before using it
New python executable in toggletest\Scripts\python.exe
Installing setuptools................done.
Installing pip...................done.
(toggletest) C:\Dropbox\Code>lssitepackages
dir /b "C:\Dropbox\Code\virtualenvs\toggletest\Lib\site-packages"
==============================================================================
easy-install.pth
pip-1.3.1-py2.7.egg
setuptools-0.6c11-py2.7.egg
setuptools.pth
C:\Dropbox\Code\virtualenvs\toggletest\Lib\site-packages\easy-install.pth
==============================================================================
import sys; sys.__plen = len(sys.path)
./setuptools-0.6c11-py2.7.egg
./pip-1.3.1-py2.7.egg
import sys; new=sys.path[sys.__plen:]; del sys.path[sys.__plen:]; p=getattr(sys,'__egginsert',0); sys.path[p:p]=new; sys.__egginsert = p+len(new)
(toggletest) C:\Dropbox\Code>toggleglobalsitepackages
Enabled global site-packages
(toggletest) C:\Dropbox\Code>lssitepackages
dir /b "C:\Dropbox\Code\virtualenvs\toggletest\Lib\site-packages"
==============================================================================
easy-install.pth
pip-1.3.1-py2.7.egg
setuptools-0.6c11-py2.7.egg
setuptools.pth
C:\Dropbox\Code\virtualenvs\toggletest\Lib\site-packages\easy-install.pth
==============================================================================
import sys; sys.__plen = len(sys.path)
./setuptools-0.6c11-py2.7.egg
./pip-1.3.1-py2.7.egg
import sys; new=sys.path[sys.__plen:]; del sys.path[sys.__plen:]; p=getattr(sys,'__egginsert',0); sys.path[p:p]=new; sys.__egginsert = p+len(new)
(toggletest) C:\Dropbox\Code>toggleglobalsitepackages
Disabled global site-packages
(toggletest) C:\Dropbox\Code>lssitepackages
dir /b "C:\Dropbox\Code\virtualenvs\toggletest\Lib\site-packages"
==============================================================================
easy-install.pth
pip-1.3.1-py2.7.egg
setuptools-0.6c11-py2.7.egg
setuptools.pth
C:\Dropbox\Code\virtualenvs\toggletest\Lib\site-packages\easy-install.pth
==============================================================================
import sys; sys.__plen = len(sys.path)
./setuptools-0.6c11-py2.7.egg
./pip-1.3.1-py2.7.egg
import sys; new=sys.path[sys.__plen:]; del sys.path[sys.__plen:]; p=getattr(sys,'__egginsert',0); sys.path[p:p]=new; sys.__egginsert = p+len(new)
(toggletest) C:\Dropbox\Code>
The Linux version of mkvirtualenv has 3 options in addition to those that get passed through to to virtualenv. virtualenvwrapper-win doesn't not currently support these. Can they be added?
Usage: mkvirtualenv [-a project_path] [-i package] [-r requirements_file]
[virtualenv options] env_name
-a project_path
Provide a full path to a project directory to associate with
the new environment.
-i package
Install a package after the environment is created.
This option may be repeated.
-r requirements_file
Provide a pip requirements file to install a base set of packages
into the new environment.
When I set WORKON_HOME manually an then do mkvirtualenv MYENV
installing packages in this env installs everything to main Python installation on C:\Python27. Don´t know if it matters but I used a requirements.txt to install packages in MYENV like so pip install -r requirements.txt
Also after workon MYENV
the deactivate
command seemed not to work properly.
System: Windows 7, 64bit
Just noting in readme docs that currently Python 2.5-3.3 is that a correct limitation and 3.4 and 3.5 are not supported on windows?
When creating a new virtual environment it creates an activate.bat file with a hardcoded pathname at the top:
@echo off
set VIRTUAL_ENV=C:\Dropbox\virtualenvs\myproject
This is because WORKON_HOME
is set to C:\Dropbox\virtualenvs
. However on other machines Dropbox may be located elsewhere, for example F:\Dropbox\virtualenvs
, which breaks the activation script.
Is it possible to change the virtualenv creation to use the environment variable instead? That is, change the above to:
@echo off
set VIRTUAL_ENV=%WORKON_HOME%\myproject
1.0.9 worked for me, but the install via pip only installs the "virtualenvwrapper_win-1.1.3-py3.3.egg-info" dir -- no scripts. And the source install using python setup.py install
fails with:
"error: file 'C:\Users\dhobbs\scripts\add2virtualenv.bat' does not exist" (C:\Users\dhobbs was my current dir).
This is on Win7-64 using Python 2.7 and 3.3.
Failure looks like this:
Using base prefix 'C:\\Python34'
New python executable in moveit\Scripts\python.exe
Failed to import the site module
Traceback (most recent call last):
File "C:\Work\ICG\.envs\moveit\lib\site.py", line 67, in <module>
import os
File "C:\Work\ICG\.envs\moveit\lib\os.py", line 614, in <module>
from _collections_abc import MutableMapping
ImportError: No module named '_collections_abc'
ERROR: The executable moveit\Scripts\python.exe is not functioning
ERROR: It thinks sys.prefix is 'c:\\work\\icg\\.envs' (should be 'c:\\work\\icg\
\.envs\\moveit')
ERROR: virtualenv is not compatible with this system or executable
Note: some Windows users have reported this error when they installed Python for
"Only this user" or have multiple versions of Python installed. Copying the app
ropriate PythonXX.dll to the virtualenv Scripts/ directory may fix this problem.
I tried moving the dll, but as the rest of the virtualenv isn't set up yet, it doesn't allow it to be used. I'll investigate, but if anyone has advice, much appreciated.
Command setprojectdir
isn't working properly because it writes project directory path in active virtualenv's %ENVNAME%\Lib\site-packages\virtualenv_path_extensions.pth
file while cdproject
is looking for path in %ENVNAME%\.project
file.
Hi,
Got failed when I tried to create a new env for python3.2.
My system:
Win7 64bit
Currently I have python2.6(amd 64bit) and python3.2(amd 64bit), and python2.6 is the default.
After I intalled virtualenvwrapper, "mkvirtualenv py26" is OK, and I see py26 under WORKON_HOME.
But,when I issue "mkvirtualenv --python E:\Python32\python.exe py32", firstly, a pop-up window comes up,indicating python.exe has stopped working, and after I press the cancel button, I got the following error messages:
The system cannot find the path specified.
The system cannot find the path specified.
The system cannot find the path specified.
Here is output of pyassoc.bat without echo off and where python.exe:
D:\Python26\Scripts>pyassoc.bat
D:\Python26\Scripts>if defined VIRTUAL_ENV (call "\Scripts\deactivate.bat" )
D:\Python26\Scripts>if defined PYTHONHOME (goto MAIN )
D:\Python26\Scripts>REM Detect if the user is running in elevated mode.
D:\Python26\Scripts>REM Relies on requiring admin privileges to read the LOCAL SERVICE account reg k
ey.
D:\Python26\Scripts>reg query "HKU\S-1-5-19" 1>NUL 2>NUL
D:\Python26\Scripts>assoc .pyc=Python.CompiledFile 1>NUL 2>NUL
D:\Python26\Scripts>ftype Python.CompiledFile="D:\Python26\Scripts\python.bat" "%1" %* 1>NUL 2>NUL
D:\Python26\Scripts>assoc .py=Python.File 1>NUL 2>NUL
D:\Python26\Scripts>ftype Python.File="D:\Python26\Scripts\python.bat" "%1" %* 1>NUL 2>NUL
.py files will launch with "D:\Python26\Scripts\python.bat" "%1" %*
D:\Python26\Scripts>
D:\Python26\Scripts>
D:\Python26\Scripts>where python.exe
D:\Python26\python.exe
D:\Python26\Scripts>
Would you please have a look?
Thanks.
Weslie
It is a vista & windows 7 tool.
A suitable version is found in Windows 2003 server & Windows 2000 Resource Kit.
This is my easy_install error
Extracting in c:\users\saytha1\appdata\local\temp\easy_install-yxnvih\virtualen1\appdata\local\temp\easy_install-yxnvih\virtuale
vwrapper-win-1.1.5\temp\tmpj5mwnr
Now working in c:\users\saytha
nvwrapper-win-1.1.5\temp\tmpj5mwnr\distribute-0.6.46
Building a Distribute egg in c:\users\saytha1\appdata\local\temp\easy_install-y1\appdata\local\temp\easy_install-yxnvih\virtualenvwrapper-win-1
xnvih\virtualenvwrapper-win-1.1.5
warning: no files found matching 'Makefile' under directory 'docs'
warning: no files found matching 'indexsidebar.html' under directory 'docs'
c:\users\saytha
.1.5\distribute-0.6.46-py2.7.egg
C:\Python27\lib\distutils\dist.py:267: UserWarning: Unknown distribution option:
'zip_safe'
warnings.warn(msg)
C:\Python27\lib\distutils\dist.py:267: UserWarning: Unknown distribution option:
'install_requires'
warnings.warn(msg)
warning: install_lib: 'build\lib' does not exist -- no Python modules to install
It continues to go from there but this seems consistent with where my pip install errors as well.
Using tcc/le gives an error message - this is probably as it has some slightly different syntax occasionally
http://jpsoft.com/tccle-cmd-replacement.html
[C:\Program Files\ConEmu]mkvirtualenv emessage
PYTHONHOME is set. You *must* activate the virtualenv before using it
New python executable in emessage\Scripts\python.exe
Installing setuptools................done.
Installing pip...................done.
TCC: C:\Python26\mkvirtualenv.bat [84] Unbalanced parentheses "( echo.:: In cas
e user makes changes to PYTHONPATH & echo.if defined _OLD_VIRTUAL_PYTHONPATH ( e
cho. set "PYTHONPATH=%%_OLD_VIRTUAL_PYTHONPATH%%" & echo.^) else ( echo. s
et "_OLD_VIRTUAL_PYTHONPATH=%%PYTHONPATH%%" & echo.^) ) & >>"%WORKON_HOME%\%ENVN
AME%\Scripts\deactivate.bat" ( echo. & echo.if defined _OLD_VIRTUAL_PYTHONPATH (
echo. set "PYTHONPATH=%%_OLD_VIRTUAL_PYTHONPATH%%" & echo.^) ) & call "%WORK
ON_HOME%\%ENVNAME%\Scripts\activate.bat" & goto END & :GET_ENVNAME & set "ENVNAM
E=%~1" & shift & if not "%~1"=="" goto GET_ENVNAME & goto :eof & :END & set PYHO
ME= & set ENVNAME= "
After installing on a Win8 machine via pip,
mkvirtualenv test
produces the following output:
D:\code\test>mkvirtualenv test
Using base prefix 'c:\\program files (x86)\\python 3.5'
New python executable in test\Scripts\python.exe
Installing setuptools, pip, wheel...
Complete output from command C:\Users\Chen\Envs\test\Scripts\python.exe -c "import sys, pip; sys...d\"] + sys.argv[1:]))" setuptools pip wheel:
Ignoring indexes: https://pypi.python.org/simple
Collecting setuptools
The repository located at None is not a trusted or secure host and is being ignored. If this repository is available via HTTPS it is recommended to use HTTPS instead, otherwise you may silence this warning and allow it anyways with '--trusted-host None'.
The repository located at None is not a trusted or secure host and is being ignored. If this repository is available via HTTPS it is recommended to use HTTPS instead, otherwise you may silence this warning and allow it anyways with '--trusted-host None'.
The repository located at None is not a trusted or secure host and is being ignored. If this repository is available via HTTPS it is recommended to use HTTPS instead, otherwise you may silence this warning and allow it anyways with '--trusted-host None'.
The repository located at None is not a trusted or secure host and is being ignored. If this repository is available via HTTPS it is recommended to use HTTPS instead, otherwise you may silence this warning and allow it anyways with '--trusted-host None'.
The repository located at None is not a trusted or secure host and is being ignored. If this repository is available via HTTPS it is recommended to use HTTPS instead, otherwise you may silence this warning and allow it anyways with '--trusted-host None'.
The repository located at None is not a trusted or secure host and is being ignored. If this repository is available via HTTPS it is recommended to use HTTPS instead, otherwise you may silence this warning and allow it anyways with '--trusted-host None'.
The repository located at None is not a trusted or secure host and is being ignored. If this repository is available via HTTPS it is recommended to use HTTPS instead, otherwise you may silence this warning and allow it anyways with '--trusted-host None'.
The repository located at None is not a trusted or secure host and is being ignored. If this repository is available via HTTPS it is recommended to use HTTPS instead, otherwise you may silence this warning and allow it anyways with '--trusted-host None'.
The repository located at None is not a trusted or secure host and is being ignored. If this repository is available via HTTPS it is recommended to use HTTPS instead, otherwise you may silence this warning and allow it anyways with '--trusted-host None'.
The repository located at None is not a trusted or secure host and is being ignored. If this repository is available via HTTPS it is recommended to use HTTPS instead, otherwise you may silence this warning and allow it anyways with '--trusted-host None'.
The repository located at None is not a trusted or secure host and is being ignored. If this repository is available via HTTPS it is recommended to use HTTPS instead, otherwise you may silence this warning and allow it anyways with '--trusted-host None'.
The repository located at None is not a trusted or secure host and is being ignored. If this repository is available via HTTPS it is recommended to use HTTPS instead, otherwise you may silence this warning and allow it anyways with '--trusted-host None'.
Could not find a version that satisfies the requirement setuptools (from versions: )
No matching distribution found for setuptools
----------------------------------------
...Installing setuptools, pip, wheel...done.
Traceback (most recent call last):
File "c:\program files (x86)\python 3.5\lib\runpy.py", line 170, in _run_module_as_main
"__main__", mod_spec)
File "c:\program files (x86)\python 3.5\lib\runpy.py", line 85, in _run_code
exec(code, run_globals)
File "C:\Program Files (x86)\Python 3.5\Scripts\virtualenv.exe\__main__.py", line 9, in <module>
File "c:\program files (x86)\python 3.5\lib\site-packages\virtualenv.py", line 832, in main
symlink=options.symlink)
File "c:\program files (x86)\python 3.5\lib\site-packages\virtualenv.py", line 1004, in create_environment
install_wheel(to_install, py_executable, search_dirs)
File "c:\program files (x86)\python 3.5\lib\site-packages\virtualenv.py", line 969, in install_wheel
'PIP_NO_INDEX': '1'
File "c:\program files (x86)\python 3.5\lib\site-packages\virtualenv.py", line 910, in call_subprocess
% (cmd_desc, proc.returncode))
OSError: Command C:\Users\Chen\Envs\test\Scripts\python.exe -c "import sys, pip; sys...d\"] + sys.argv[1:]))" setuptools pip wheel failed with error code 1
Here's what I get on running pip install virtualenvwrapper-win:
C:\Python27\Scripts\pip-script.py run on 10/27/13 22:08:14
Downloading/unpacking virtualenvwrapper-win
Getting page https://pypi.python.org/simple/virtualenvwrapper-win/
URLs to search for versions for virtualenvwrapper-win:
https://pypi.python.org/simple/virtualenvwrapper-win/
Analyzing links from page https://pypi.python.org/simple/virtualenvwrapper-win/
Found link https://pypi.python.org/packages/source/v/virtualenvwrapper-win/virtualenvwrapper-win-1.0.0.zip#md5=200004aa2721ff3d0db13415b83bbff8 (from https://pypi.python.org/simple/virtualenvwrapper-win/), version: 1.0.0
Found link https://pypi.python.org/packages/source/v/virtualenvwrapper-win/virtualenvwrapper-win-1.0.1.zip#md5=dacacef0eb8b5731e989dd47ff9e2d66 (from https://pypi.python.org/simple/virtualenvwrapper-win/), version: 1.0.1
Found link https://pypi.python.org/packages/source/v/virtualenvwrapper-win/virtualenvwrapper-win-1.0.2.zip#md5=369bb5bef612abff8bc4287943fd34f6 (from https://pypi.python.org/simple/virtualenvwrapper-win/), version: 1.0.2
Found link https://pypi.python.org/packages/source/v/virtualenvwrapper-win/virtualenvwrapper-win-1.0.3.zip#md5=b32bf1bbaae51388e3d6b280e2864d52 (from https://pypi.python.org/simple/virtualenvwrapper-win/), version: 1.0.3
Found link https://pypi.python.org/packages/source/v/virtualenvwrapper-win/virtualenvwrapper-win-1.0.4.zip#md5=3823da590879d3810d6b2fd4f27e096f (from https://pypi.python.org/simple/virtualenvwrapper-win/), version: 1.0.4
Found link https://pypi.python.org/packages/source/v/virtualenvwrapper-win/virtualenvwrapper-win-1.0.5.zip#md5=b70666db344075622603dd7e8ea1fb3a (from https://pypi.python.org/simple/virtualenvwrapper-win/), version: 1.0.5
Found link https://pypi.python.org/packages/source/v/virtualenvwrapper-win/virtualenvwrapper-win-1.0.6.zip#md5=8b546adadddcd643d9b0931b173abff2 (from https://pypi.python.org/simple/virtualenvwrapper-win/), version: 1.0.6
Found link https://pypi.python.org/packages/source/v/virtualenvwrapper-win/virtualenvwrapper-win-1.0.7.zip#md5=4107c7f4891861c834ce7f0a7a42dae9 (from https://pypi.python.org/simple/virtualenvwrapper-win/), version: 1.0.7
Found link https://pypi.python.org/packages/source/v/virtualenvwrapper-win/virtualenvwrapper-win-1.0.8.zip#md5=5a7d11528bf739bd86fbc067ba82602a (from https://pypi.python.org/simple/virtualenvwrapper-win/), version: 1.0.8
Found link https://pypi.python.org/packages/source/v/virtualenvwrapper-win/virtualenvwrapper-win-1.0.9.zip#md5=3f79c140b655ec0a2b43374d3c226a5f (from https://pypi.python.org/simple/virtualenvwrapper-win/), version: 1.0.9
Found link https://pypi.python.org/packages/source/v/virtualenvwrapper-win/virtualenvwrapper-win-1.1.3.zip#md5=c5b987d0d8f7678e0f9ea7e52c4c9213 (from https://pypi.python.org/simple/virtualenvwrapper-win/), version: 1.1.3
Found link https://pypi.python.org/packages/source/v/virtualenvwrapper-win/virtualenvwrapper-win-1.1.4.zip#md5=b28bddb9262c767eec6ee17534f20fc1 (from https://pypi.python.org/simple/virtualenvwrapper-win/), version: 1.1.4
Found link https://pypi.python.org/packages/source/v/virtualenvwrapper-win/virtualenvwrapper-win-1.1.5.zip#md5=0494dd281c82f6efc5017645c4bfacf0 (from https://pypi.python.org/simple/virtualenvwrapper-win/), version: 1.1.5
Using version 1.1.5 (newest of versions: 1.1.5, 1.1.4, 1.1.3, 1.0.9, 1.0.8, 1.0.7, 1.0.6, 1.0.5, 1.0.4, 1.0.3, 1.0.2, 1.0.1, 1.0.0)
Downloading virtualenvwrapper-win-1.1.5.zip
Downloading from URL https://pypi.python.org/packages/source/v/virtualenvwrapper-win/virtualenvwrapper-win-1.1.5.zip#md5=0494dd281c82f6efc5017645c4bfacf0 (from https://pypi.python.org/simple/virtualenvwrapper-win/)
Running setup.py egg_info for package virtualenvwrapper-win
Downloading http://pypi.python.org/packages/source/d/distribute/distribute-0.6.46.tar.gz
Extracting in c:\users\gweiny~1\appdata\local\temp\tmp133tzn
Now working in c:\users\gweiny~1\appdata\local\temp\tmp133tzn\distribute-0.6.46
Building a Distribute egg in c:\users\gweiny~1\appdata\local\temp\pip_build_gweinyddwr\virtualenvwrapper-win
c:\users\gweiny~1\appdata\local\temp\pip_build_gweinyddwr\virtualenvwrapper-win\distribute-0.6.46-py2.7.egg
C:\Python27\lib\distutils\dist.py:267: UserWarning: Unknown distribution option: 'zip_safe'
warnings.warn(msg)
C:\Python27\lib\distutils\dist.py:267: UserWarning: Unknown distribution option: 'install_requires'
warnings.warn(msg)
usage: -c [global_opts] cmd1 [cmd1_opts] [cmd2 [cmd2_opts] ...]
or: -c --help [cmd1 cmd2 ...]
or: -c --help-commands
or: -c cmd --help
error: invalid command 'egg_info'
Complete output from command python setup.py egg_info:
Downloading http://pypi.python.org/packages/source/d/distribute/distribute-0.6.46.tar.gz
Extracting in c:\users\gweiny~1\appdata\local\temp\tmp133tzn
Now working in c:\users\gweiny~1\appdata\local\temp\tmp133tzn\distribute-0.6.46
Building a Distribute egg in c:\users\gweiny~1\appdata\local\temp\pip_build_gweinyddwr\virtualenvwrapper-win
c:\users\gweiny~1\appdata\local\temp\pip_build_gweinyddwr\virtualenvwrapper-win\distribute-0.6.46-py2.7.egg
C:\Python27\lib\distutils\dist.py:267: UserWarning: Unknown distribution option: 'zip_safe'
warnings.warn(msg)
C:\Python27\lib\distutils\dist.py:267: UserWarning: Unknown distribution option: 'install_requires'
warnings.warn(msg)
usage: -c [global_opts] cmd1 [cmd1_opts] [cmd2 [cmd2_opts] ...]
or: -c --help [cmd1 cmd2 ...]
or: -c --help-commands
or: -c cmd --help
error: invalid command 'egg_info'
Cleaning up...
Removing temporary dir c:\users\gweiny1\appdata\local\temp\pip_build_gweinyddwr...1\appdata\local\temp\pip_build_gweinyddwr\virtualenvwrapper-win
Command python setup.py egg_info failed with error code 1 in c:\users\gweiny
Exception information:
Traceback (most recent call last):
File "C:\Python27\lib\site-packages\pip\basecommand.py", line 134, in main
status = self.run(options, args)
File "C:\Python27\lib\site-packages\pip\commands\install.py", line 236, in run
requirement_set.prepare_files(finder, force_root_egg_info=self.bundle, bundle=self.bundle)
File "C:\Python27\lib\site-packages\pip\req.py", line 1134, in prepare_files
req_to_install.run_egg_info()
File "C:\Python27\lib\site-packages\pip\req.py", line 259, in run_egg_info
command_desc='python setup.py egg_info')
File "C:\Python27\lib\site-packages\pip\util.py", line 670, in call_subprocess
% (command_desc, proc.returncode, cwd))
InstallationError: Command python setup.py egg_info failed with error code 1 in c:\users\gweiny~1\appdata\local\temp\pip_build_gweinyddwr\virtualenvwrapper-win
I hope you can make something of it and that I'm not wasting your time.
I installed virtualenvwrapper-win in an elevated prompt with the following commands
pip install virtualenvwrapper-win
pyassoc
but when I try running
mkvirtualenv test
I get
The system cannot find the path specified.
The system cannot find the path specified.
The system cannot find the path specified.
Yes it prints that line out three times. How come this is happening?
What's the reason for python.bat
and other batch files to set PYTHONHOME
environment variable? Python executable does not set this variable and I think setting it by python.bat
and other scripts is wrong.
In cdvirtualenv.bat, there is logic setting %_LAST_DIR% to the current directory, but nothing in deactivate.bat to change back to the %_LAST_DIR% before activating.
Before I fork/MR, is this expected behavior for some reason?
Thanks!
I got that error on Windows 7 (32 bits) installing virtualenvwrapper-win using PowerShell and normal cmd, I have UAC disabled and tried on a elevated command prompt.
This occures when I run pyassoc, showing me this:
Information: Can´t found any file for the patterns given
.py files will launch with "~0,-1\Scripts\python.bat" "%1" %*
Running Google App Engine (GAE) inside of a virtualenv requires a couple of tweaks to how the environment is configured, in part I think because GAE has its own installer and thus can't be installed via pip.
There are small number of path reconfiguration steps required to create a virtualenv that works with a GAE installation:
http://www.anler.me/blog/2012/jun/google-app-engine-in-virtualenv/
It would be great to have this as an option when creating a new virtual environment, or potentially as a new command-line script that does these steps.
When trying to user virtualenvwrapper-win, I ran into the issue as described here: pypa/virtualenv#518
I get the errors described when I do either mkvirtualenv test
or virtualenv test
from cmd.exe.
As described in that issue, this problem is fixed in virtualenv 1.11 however it seems virtualenvwrapper-win installed virtualenv 1.9.1.
If I install virtualenv 1.11.6 myself, virtualenv then works (I can do virtualenv test
without problems, but virtualenvwrapper-win doesn't (mkvirtualenv test
now gives:
python.exe: can't open file 'C:\Python34\Scripts\virtualenv-script.py': [Errno 2] No such file or directory
).
From my perspective, it seems like virtualenvwrapper-win just needs to be upgrade to include and support the most recent version of virtualenv.
Thanks,
I got No distributions at all found for virtualenvwrapper-win
when trying to install virtualenvwrapper-win with pip. I was able to install it by doing pip install https://github.com/davidmarble/virtualenvwrapper-win/zipball/master
.
C:\>pip install virtualenvwrapper-win
Downloading/unpacking virtualenvwrapper-win
Could not find any downloads that satisfy the requirement virtualenvwrapper-win
No distributions at all found for virtualenvwrapper-win
Storing complete log in q:\AppData\pip\pip.log
pip.log
Downloading/unpacking virtualenvwrapper-win
Getting page http://pypi.python.org/simple/virtualenvwrapper-win
URLs to search for versions for virtualenvwrapper-win:
* http://pypi.python.org/simple/virtualenvwrapper-win/
Getting page https://github.com/davidmarble/virtualenvwrapper-win/
Analyzing links from page http://pypi.python.org/simple/virtualenvwrapper-win/
Skipping link https://github.com/davidmarble/virtualenvwrapper-win/ (from http://pypi.python.org/simple/virtualenvwrapper-win/); not a file
Skipping link http://www.doughellmann.com/projects/virtualenvwrapper/ (from http://pypi.python.org/simple/virtualenvwrapper-win/); not a file
Analyzing links from page https://github.com/davidmarble/virtualenvwrapper-win/
Skipping link https://github.com/opensearch.xml (from https://github.com/davidmarble/virtualenvwrapper-win/); unknown archive format: .xml
Skipping link https://github.com/fluidicon.png (from https://github.com/davidmarble/virtualenvwrapper-win/); unknown archive format: .png
Skipping link https://github.com/favicon.ico (from https://github.com/davidmarble/virtualenvwrapper-win/); unknown archive format: .ico
Skipping link https://a248.e.akamai.net/assets.github.com/stylesheets/bundles/github-c2f83c57a14d5e54d816673f52563d987fe2821f.css (from https://github.com/davidmarble/virtualenvwrapper-win/); unknown archive format: .css
Skipping link https://a248.e.akamai.net/assets.github.com/stylesheets/bundles/github2-34d96ae148c427d3106177152ac475d7df36c780.css (from https://github.com/davidmarble/virtualenvwrapper-win/); unknown archive format: .css
Skipping link https://github.com/davidmarble/virtualenvwrapper-win/tree/ea742e6a561651e02ec27e79c542caca3d907cd1 (from https://github.com/davidmarble/virtualenvwrapper-win/); not a file
Skipping link https://github.com/davidmarble/virtualenvwrapper-win/commits/master.atom (from https://github.com/davidmarble/virtualenvwrapper-win/); unknown archive format: .atom
Skipping link https://github.com (from https://github.com/davidmarble/virtualenvwrapper-win/); not a file
Skipping link https://github.com/plans (from https://github.com/davidmarble/virtualenvwrapper-win/); not a file
Skipping link https://github.com/explore (from https://github.com/davidmarble/virtualenvwrapper-win/); not a file
Skipping link https://github.com/features (from https://github.com/davidmarble/virtualenvwrapper-win/); not a file
Skipping link https://github.com/blog (from https://github.com/davidmarble/virtualenvwrapper-win/); not a file
Skipping link https://github.com/login?return_to=%2Fdavidmarble%2Fvirtualenvwrapper-win%2F (from https://github.com/davidmarble/virtualenvwrapper-win/); not a file
Skipping link https://github.com/davidmarble (from https://github.com/davidmarble/virtualenvwrapper-win/); not a file
Skipping link https://github.com/davidmarble/virtualenvwrapper-win (from https://github.com/davidmarble/virtualenvwrapper-win/); not a file
Skipping link https://github.com/login?return_to=%2Fdavidmarble%2Fvirtualenvwrapper-win (from https://github.com/davidmarble/virtualenvwrapper-win/); not a file
Skipping link https://github.com/davidmarble/virtualenvwrapper-win/watchers (from https://github.com/davidmarble/virtualenvwrapper-win/); not a file
Skipping link https://github.com/davidmarble/virtualenvwrapper-win/network (from https://github.com/davidmarble/virtualenvwrapper-win/); not a file
Skipping link https://github.com/davidmarble/virtualenvwrapper-win/pulls (from https://github.com/davidmarble/virtualenvwrapper-win/); not a file
Skipping link https://github.com/davidmarble/virtualenvwrapper-win/issues (from https://github.com/davidmarble/virtualenvwrapper-win/); not a file
Skipping link https://github.com/davidmarble/virtualenvwrapper-win/graphs (from https://github.com/davidmarble/virtualenvwrapper-win/); not a file
Skipping link https://github.com/languages/Shell (from https://github.com/davidmarble/virtualenvwrapper-win/); not a file
Skipping link https://github.com/davidmarble/virtualenvwrapper-win/#readme (from https://github.com/davidmarble/virtualenvwrapper-win/); not a file
Skipping link http:// (from https://github.com/davidmarble/virtualenvwrapper-win/); not a file
Skipping link https://github.com/davidmarble/virtualenvwrapper-win/zipball/master (from https://github.com/davidmarble/virtualenvwrapper-win/); not a file
Skipping link https://github.com/davidmarble/virtualenvwrapper-win.git (from https://github.com/davidmarble/virtualenvwrapper-win/); unknown archive format: .git
Skipping link git://github.com/davidmarble/virtualenvwrapper-win.git (from https://github.com/davidmarble/virtualenvwrapper-win/); unknown archive format: .git
Skipping link https://github.com/davidmarble/virtualenvwrapper-win/dismiss-tree-finder-help (from https://github.com/davidmarble/virtualenvwrapper-win/); not a file
Skipping link https://github.com/davidmarble/virtualenvwrapper-win/tags (from https://github.com/davidmarble/virtualenvwrapper-win/); not a file
Skipping link https://github.com/davidmarble/virtualenvwrapper-win/downloads (from https://github.com/davidmarble/virtualenvwrapper-win/); not a file
Skipping link javascript:; (from https://github.com/davidmarble/virtualenvwrapper-win/); not a file
Skipping link https://github.com/davidmarble/virtualenvwrapper-win/tree/master (from https://github.com/davidmarble/virtualenvwrapper-win/); not a file
Skipping link https://github.com/davidmarble/virtualenvwrapper-win/commits/master (from https://github.com/davidmarble/virtualenvwrapper-win/); not a file
Skipping link https://github.com/davidmarble/virtualenvwrapper-win/branches (from https://github.com/davidmarble/virtualenvwrapper-win/); not a file
Skipping link https://github.com/davidmarble/virtualenvwrapper-win/commit/ea742e6a561651e02ec27e79c542caca3d907cd1 (from https://github.com/davidmarble/virtualenvwrapper-win/); not a file
Skipping link https://github.com/davidmarble/virtualenvwrapper-win/commits/master/ (from https://github.com/davidmarble/virtualenvwrapper-win/); not a file
Skipping link https://github.com/davidmarble/virtualenvwrapper-win/tree/ea742e6a561651e02ec27e79c542caca3d907cd1/scripts (from https://github.com/davidmarble/virtualenvwrapper-win/); not a file
Skipping link https://github.com/davidmarble/virtualenvwrapper-win/commit/d91ef4370da6647647b2806e5d89f3b4ed960c0a (from https://github.com/davidmarble/virtualenvwrapper-win/); not a file
Skipping link https://github.com/davidmarble/virtualenvwrapper-win/blob/ea742e6a561651e02ec27e79c542caca3d907cd1/.gitignore (from https://github.com/davidmarble/virtualenvwrapper-win/); not a file
Skipping link https://github.com/davidmarble/virtualenvwrapper-win/blob/ea742e6a561651e02ec27e79c542caca3d907cd1/README.rst (from https://github.com/davidmarble/virtualenvwrapper-win/); unknown archive format: .rst
Skipping link https://github.com/davidmarble/virtualenvwrapper-win/blob/ea742e6a561651e02ec27e79c542caca3d907cd1/setup.py (from https://github.com/davidmarble/virtualenvwrapper-win/); unknown archive format: .py
Skipping link http://pypi.python.org/pypi/virtualenv (from https://github.com/davidmarble/virtualenvwrapper-win/); not a file
Skipping link https://github.com/about (from https://github.com/davidmarble/virtualenvwrapper-win/); not a file
Skipping link https://github.com/contact (from https://github.com/davidmarble/virtualenvwrapper-win/); not a file
Skipping link https://github.com/training (from https://github.com/davidmarble/virtualenvwrapper-win/); not a file
Skipping link http://enterprise.github.com/ (from https://github.com/davidmarble/virtualenvwrapper-win/); not a file
Skipping link http://status.github.com/ (from https://github.com/davidmarble/virtualenvwrapper-win/); not a file
Skipping link http://get.gaug.es/ (from https://github.com/davidmarble/virtualenvwrapper-win/); not a file
Skipping link http://speakerdeck.com (from https://github.com/davidmarble/virtualenvwrapper-win/); not a file
Skipping link https://gist.github.com (from https://github.com/davidmarble/virtualenvwrapper-win/); not a file
Skipping link http://mac.github.com/ (from https://github.com/davidmarble/virtualenvwrapper-win/); not a file
Skipping link http://mobile.github.com/ (from https://github.com/davidmarble/virtualenvwrapper-win/); not a file
Skipping link http://jobs.github.com/ (from https://github.com/davidmarble/virtualenvwrapper-win/); not a file
Skipping link http://shop.github.com/ (from https://github.com/davidmarble/virtualenvwrapper-win/); not a file
Skipping link http://octodex.github.com/ (from https://github.com/davidmarble/virtualenvwrapper-win/); not a file
Skipping link http://help.github.com/ (from https://github.com/davidmarble/virtualenvwrapper-win/); not a file
Skipping link http://developer.github.com/ (from https://github.com/davidmarble/virtualenvwrapper-win/); not a file
Skipping link http://github.github.com/github-flavored-markdown/ (from https://github.com/davidmarble/virtualenvwrapper-win/); not a file
Skipping link http://pages.github.com/ (from https://github.com/davidmarble/virtualenvwrapper-win/); not a file
Skipping link https://github.com/site/terms (from https://github.com/davidmarble/virtualenvwrapper-win/); not a file
Skipping link https://github.com/site/privacy (from https://github.com/davidmarble/virtualenvwrapper-win/); not a file
Skipping link https://github.com/security (from https://github.com/davidmarble/virtualenvwrapper-win/); not a file
Skipping link http://www.rackspace.com (from https://github.com/davidmarble/virtualenvwrapper-win/); not a file
Skipping link http://www.rackspace.com%20 (from https://github.com/davidmarble/virtualenvwrapper-win/); not a file
Skipping link http://www.rackspacecloud.com (from https://github.com/davidmarble/virtualenvwrapper-win/); not a file
Could not find any downloads that satisfy the requirement virtualenvwrapper-win
No distributions at all found for virtualenvwrapper-win
Exception information:
Traceback (most recent call last):
File "C:\Python27\lib\site-packages\pip\basecommand.py", line 126, in main
self.run(options, args)
File "C:\Python27\lib\site-packages\pip\commands\install.py", line 223, in run
requirement_set.prepare_files(finder, force_root_egg_info=self.bundle, bundle=self.bundle)
File "C:\Python27\lib\site-packages\pip\req.py", line 954, in prepare_files
url = finder.find_requirement(req_to_install, upgrade=self.upgrade)
File "C:\Python27\lib\site-packages\pip\index.py", line 152, in find_requirement
raise DistributionNotFound('No distributions at all found for %s' % req)
DistributionNotFound: No distributions at all found for virtualenvwrapper-win
Just installed virtualenvwrapper-win on Win8 Pro x64. Here's what I'm seeing
C:\>mkvirtualenv foo
PYTHONHOME is set. You *must* activate the virtualenv before using it
New python executable in foo\Scripts\python.exe
Installing setuptools................done.
Installing pip...................done.
The system cannot find the path specified.
C:\>workon foo
The system cannot find the path specified.
I'm using ActiveState Python 2.7.2. Here's what's installed:
C:\>pip freeze
Jinja2==2.7.1
MarkupSafe==0.18
Pygments==1.5
Sphinx==1.2b1
distribute==0.7.3
docutils==0.11
ipython==0.13
pypm==1.3.4
pyreadline==2.0-dev1
pythonselect==1.3
pywin32==214
virtualenv==1.8.2
virtualenvwrapper-win==1.0.9
wsgiref==0.1.2
WORKON_HOME is set:
C:\>set WORKON_HOME
WORKON_HOME=%USERPROFILE%\Envs
Any ideas?
I am trying to install fabric into a virtual environment using python 2.7 on Windows 7. I have pycrypto installed in my global site packages, and would like to inherit this, but can't seem to get it to show up. I've confirmed I can import it from python normally, but it does not show up when launching from within the virtualenv, regardless of toggle.
Here's an example showing it working outside of virtualenv, then failing from within a virtual environment named "foobar". Any suggestions? I include a lssitepackages
listing as well, in case that helps.
C:\Users\felciano>python
ActivePython 2.7.2.5 (ActiveState Software Inc.) based on
Python 2.7.2 (default, Jun 24 2011, 12:21:10) [MSC v.1500 32 bit (Intel)] on win32
Type "help", "copyright", "credits" or "license" for more information.
>>> from Crypto.Cipher import AES
>>> ^Z
C:\Users\felciano>workon foobar
(foobar) C:\Users\felciano>toggleglobalsitepackages
Disabled global site-packages
(foobar) C:\Users\felciano>toggleglobalsitepackages
Enabled global site-packages
(foobar) C:\Users\felciano>python
ActivePython 2.7.2.5 (ActiveState Software Inc.) based on
Python 2.7.2 (default, Jun 24 2011, 12:21:10) [MSC v.1500 32 bit (Intel)] on win32
Type "help", "copyright", "credits" or "license" for more information.
>>> from Crypto.Cipher import AES
Traceback (most recent call last):
File "<stdin>", line 1, in <module>
ImportError: No module named Crypto.Cipher
>>> ^Z
(foobar) C:\Users\felciano>toggleglobalsitepackages
Disabled global site-packages
(foobar) C:\Users\felciano>toggleglobalsitepackages
Enabled global site-packages
(foobar) C:\Users\felciano>lssitepackages
dir /b "C:\Dropbox\Code\virtualenvs\foobar\Lib\site-packages"
==============================================================================
easy-install.pth
fabfile
fabric
Fabric-1.6.0-py2.7.egg-info
paramiko
paramiko-1.10.0-py2.7.egg-info
pip-1.3.1-py2.7.egg
setuptools-0.6c11-py2.7.egg
setuptools.pth
C:\Dropbox\Code\virtualenvs\foobar\Lib\site-packages\easy-install.pth
==============================================================================
import sys; sys.__plen = len(sys.path)
./setuptools-0.6c11-py2.7.egg
./pip-1.3.1-py2.7.egg
import sys; new=sys.path[sys.__plen:]; del sys.path[sys.__plen:]; p=getattr(sys,'__egginsert',0); sys. path[p:p]=new; sys.__egginsert = p+len(new)
(foobar) C:\Users\felciano>
When I issue the lsvirtualenv
, mkvirtualenv
and rmvirtualenv
commands, I get the following error:
'echo.' is not recognized as an internal or external command,
operable program or batch file.
The error might appear more than once in the output. Apart from that, the commands seem to work. For example lsvirtualenv
seems to list the existing virtualenvs (in addition to displaying the annoying error). And mkvirtualenv
seems to create the venv successfully, again whilst displaying the error a number of times.
Thank you
I get this error:
C:\Program Files (x86)\Console2>pip install virtualenvwrapper_win
Downloading/unpacking virtualenvwrapper-win
Downloading virtualenvwrapper-win-1.1.win-amd64.zip
Running setup.py egg_info for package virtualenvwrapper-win
Traceback (most recent call last):
File "<string>", line 16, in <module>
IOError: [Errno 2] No such file or directory: 'c:\\users\\andrew\\appdata\\local\\temp\\pip-build-Andrew\\virtualenvwrapper-win\\setup.py'
Complete output from command python setup.py egg_info:
Traceback (most recent call last):
File "<string>", line 16, in <module>
IOError: [Errno 2] No such file or directory: 'c:\\users\\andrew\\appdata\\local\\temp\\pip-build-Andrew\\virtualenvwrapper-win\\setup.py'
----------------------------------------
Command python setup.py egg_info failed with error code 1 in c:\users\andrew\appdata\local\temp\pip-build-Andrew\virtualenvwrapper-win
Storing complete log in C:\Users\Andrew\pip\pip.log
I notice it downloaded the *-amd64 version, but I have Python 32-bit installed on my 64-bit computer. Not sure if that's the issue.
Virtualenvwrapper does not do this (https://bitbucket.org/dhellmann/virtualenvwrapper/src/a933b98cded25b7bebbf894d494174cd3984f113/requirements.txt?at=4.1.1) and neither should we.
The reasoning being:
a) subsequent versions of virtualenv are backwards compatible so there's no need for pinning it
b) installation of an extension should not change version of base tool
rmvirtualenv
is leaving straggler files in the root folder:
pip
now creates a pip-selfcheck.json file in the virtualenv rootLICENSE
and COPYRIGHT
files to the virtualenv rootIf the script doesn't clean up these files, it's left in a funky state where rmvirtualenv
completes without removing the parent folder. This causes mkvirtualenv
to think the env exists. Ultimately, we must remove the folder by hand to fix the issue.
Am I correct in thinking this does not support hook scripts? (I looked at workon.bat and didn't see where they would be activated.)
If not, a feature request would be to support them.
Thanks for this project, by the way -- it makes my time in Windows a lot less painful.
A declarative, efficient, and flexible JavaScript library for building user interfaces.
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google ❤️ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.