python - Microsoft Visual C++ 10.0 is required. Get it with "Microsoft Windows SDK 7.1": www.microsoft.com/download/details.aspx?id=8279 -
** microsoft visual c++ 10.0 required. "microsoft windows sdk 7.1": www.microsoft.com/download/details.aspx?id=8279**
i getting error when installing mysqlclient or mysql-python
by pip install mysqlclient
i have updated , not using of visual studio produsct using sublime text please me !
i wanted test whether i've stated in comment true, attempted pip install
ing mysqlclient in 1 of ([pypa]: virtualenved) python (v2.7.13) installations:
e:\work\dev\venvs\py2713x64-test>scripts\pip.exe install -v mysqlclient config variable 'py_debug' unset, python abi tag may incorrect config variable 'with_pymalloc' unset, python abi tag may incorrect config variable 'py_unicode_size' unset, python abi tag may incorrect collecting mysqlclient 1 location(s) search versions of mysqlclient: * https://pypi.python.org/simple/mysqlclient/ getting page https://pypi.python.org/simple/mysqlclient/ looking "https://pypi.python.org/simple/mysqlclient/" in cache no cache entry available starting new https connection (1): pypi.python.org "get /simple/mysqlclient/ http/1.1" 200 2671 updating cache response "https://pypi.python.org/simple/mysqlclient/" caching b/c date exists , max-age > 0 analyzing links page https://pypi.python.org/simple/mysqlclient/ ... lots of crap ... no cache entry available "get /packages/40/9b/0bc869f290b8f49a99b8d97927f57126a5d1befcf8bac92c60dc855f2523/mysqlclient-1.3.10.tar.gz http/1.1" 200 82102 downloading mysqlclient-1.3.10.tar.gz (82kb) downloading url https://pypi.python.org/packages/40/9b/0bc869f290b8f49a99b8d97927f57126a5d1befcf8bac92c60dc855f2523/mysqlclient-1.3.10.tar.gz#md5=e7fb95c4055e2d8a3322db5c85ab6fc8 (from https://pypi.python.org/simple/mysqlclient/) 99% |############################### | 81kb 252kb/s eta 0:00:01 updating cache response "https://pypi.python.org/packages/40/9b/0bc869f290b8f49a99b8d97927f57126a5d1befcf8bac92c60dc855f2523/mysqlclient-1.3.10.tar.gz" ... other crap ... running build_ext building '_mysql' extension error: microsoft visual c++ 9.0 required. http://aka.ms/vcpython27 error failed building wheel mysqlclient
what happening:
- it connects https://pypi.python.org/simple/mysqlclient
- it checks latest version: 1.3.10
since version compiled python3.5 , python3.6 (32/64 bit):
- mysqlclient-1.3.10-cp35-cp35m-win32.whl
- mysqlclient-1.3.10-cp35-cp35m-win_amd64.whl
- mysqlclient-1.3.10-cp36-cp36m-win32.whl
- mysqlclient-1.3.10-cp36-cp36m-win_amd64.whl
it downloads source archive: mysqlclient-1.3.10.tar.gz
- the archive contains (besides python files, installation files , other additional files) file: _mysql.c, backend communicating mysql. stated, in order use c code, has compiled dll (_mysql.pyd). more info on building (compiling) c code, check answer to: [so]: lnk2005 error in clr windows form
- now, since dll loaded python when importing mysqlclient, has compiled same compiler, or better: must use same c runtime python uses (well it's not must, using more 1 c runtime in process, recipe disaster in 99.99% cases), tries build microsoft visual c++ 9.0 (or vstudio2008), doesn't find it, , hence error
the thing differs in case it's microsoft visual c++ 10.0 (or vstudio2010) version, tells me you're using python3.3 or (most likely) python3.4.
possible solutions:
- download microsoft windows sdk 7.1 provided link , install (then rerun
pip install mysqlclient
command). it's 1 time step, , i'm 100% positive you'll need when you'll have install other 3rd party modules come c sources - download , install newer python version (3.5, 3.6) , run
pip
package compiled these versions - google other places download compiled version of module python version. although should careful when installing stuff untrusted sources
- [so]: python 3.4.0 mysql database mentions package: [github]: pymysql (other packages listed there well), i'm not sure how similar 2 are, give shot
Comments
Post a Comment