我正在关注如何安装python的this非常棒的步骤。
我不认为我有一个真正的问题......我想我能够在我的django项目上工作......但是我遇到了一些错误,我只是有点跳过了,我想知道它们来自哪里。
在我到达安装MySQL-python的部分之前,一切都在游动。我实际上是通过XAMPP使用MySQL ...所以如果这是问题,请告诉我。
我尝试安装MySQL-python v1.2.3并收到此错误:
Processing MySQL-python-1.2.3.win-amd64-py2.7.exe
creating 'c:\users\quentin\appdata\local\temp\easy_install-reydf8\MySQL_python-1.2.3-py2.7-win32.egg' and adding 'c:\users\quentin\appdata\local\temp\easy_install-reydf8\MySQL_python-1.2.3-py2.7-win32.egg.tmp' to it
Moving MySQL_python-1.2.3-py2.7-win32.egg to c:\virtualenvs\django_tutorial\lib\site-packages
Adding MySQL-python 1.2.3 to easy-install.pth file
Installed c:\virtualenvs\django_tutorial\lib\site-packages\mysql_python-1.2.3-py2.7-win32.egg
Processing dependencies for MySQL-python==1.2.3
Searching for MySQL-python==1.2.3
Reading http://pypi.python.org/simple/MySQL-python/
Best match: MySQL-python 1.2.3
Downloading https://pypi.python.org/packages/source/M/MySQL-python/MySQL-python-1.2.3.tar.gz#md5=215eddb6d853f6f4be5b4afc4154292f
Processing MySQL-python-1.2.3.tar.gz
Running MySQL-python-1.2.3\setup.py -q bdist_egg --dist-dir c:\users\quentin\appdata\local\temp\easy_install-cnlqlk\MySQL-python-1.2.3\egg-dist-tmp-iaalng
error: The system cannot find the file specified
通常情况下我会期望1.2.3没有安装,但我认为这样做是因为这个命令有效......
python manage.py syncdb
所以我很好奇关于找不到系统文件的错误消息来自。
我也尝试过安装v1.2.4,并且在查找其他文件时收到类似的错误:
(django_tutorial) C:\django_projects\insults>easy_install file://c:/users/quentin/downloads/mysql-python-1.2.4.win-amd64-py2.7.exe
Processing mysql-python-1.2.4.win-amd64-py2.7.exe
creating 'c:\users\quentin\appdata\local\temp\easy_install-hz3ivi\MySQL_python-1.2.4-py2.7-win32.egg' and adding 'c:\users\quentin\appdata\local\temp\easy_install-hz3ivi\MySQL_python-1.2.4-py2.7-win32.egg.tmp' to it
Moving MySQL_python-1.2.4-py2.7-win32.egg to c:\virtualenvs\django_tutorial\lib\site-packages
Removing mysql-python 1.2.3 from easy-install.pth file
Adding MySQL-python 1.2.4 to easy-install.pth file
Installed c:\virtualenvs\django_tutorial\lib\site-packages\mysql_python-1.2.4-py2.7-win32.egg
Processing dependencies for MySQL-python==1.2.4
Searching for MySQL-python==1.2.4
Reading http://pypi.python.org/simple/MySQL-python/
Best match: MySQL-python 1.2.4
Downloading https://pypi.python.org/packages/source/M/MySQL-python/MySQL-python1.2.4.zip#md5=ddf2386daf10a97af115ffad2ed4a9a0
Processing MySQL-python-1.2.4.zip
Running MySQL-python-1.2.4\setup.py -q bdist_egg --dist-dir c:\users\quentin\appdata\local\temp\easy_install-v0_gfa\MySQL-python-1.2.4\egg-dist-tmp-2ltuob
Downloading http://pypi.python.org/packages/source/d/distribute/distribute-0.6.28.tar.gz
Extracting in c:\users\quentin\appdata\local\temp\easy_install-v0_gfa\MySQL-python-1.2.4\temp\tmpemj6wf
Now working in c:\users\quentin\appdata\local\temp\easy_install-v0_gfa\MySQL-python-1.2.4\temp\tmpemj6wf\distribute-0.6.28
Building a Distribute egg in c:\users\quentin\appdata\local\temp\easy_install-v0_gfa\MySQL-python-1.2.4
c:\users\quentin\appdata\local\temp\easy_install-v0_gfa\MySQL-python-1.2.4\distribute0.6.28-py2.7.egg
error: Setup script exited with error: Unable to find vcvarsall.bat
所以是的。只是好奇这些错误以及我是否应该担心它们。我想如果事情有效,我真的没有问题,但是......其他人也可能对此感到困惑,并且也陷入了在django工作的安装/设置部分?
修改 的 好吧,当我安装1.2.4时它不高兴,但是如果我只是在它上面安装1.2.3,那么syncdb会再次运行。
MySQL-python 1.2.3 / 1.2.4
Django 1.5.1
XAMPP3.1.0,Apache2.4.3,MySQL5.5.32
Python 2.7.5 64位
Windows 7 64位
答案 0 :(得分:0)
主要问题在于:
Setup script exited with error: Unable to find vcvarsall.bat
这表示您的C
和C++
未编译。如果您最近安装了Visual Studio 2012,请按照我的回答here找到问题的解决方案。