Cant install PyTables at windows - python

I try to install the PyTables module. I use Windows 7 (x32), Python 2.7.3 (x32), Cython 0.16, Visual Studio 2008 (9.0). At cmd.exe 'run as administrator' write: 'python setup.py install --hdf5="C:\Program Files\HDF Group\HDF5\1.8.9"'.
But there are unresolved external symbols and build failed:
* Found numpy 1.6.2 package installed.
* Found numexpr 2.0.1 package installed.
* Found Cython 0.16 package installed.
* Found HDF5 headers at ``C:\Program Files\HDF Group\HDF5\1.8.9\include``, libra
ry at ``C:\Program Files\HDF Group\HDF5\1.8.9\lib``.
* Could not find LZO 2 headers and library; disabling support for it.
* Could not find LZO 1 headers and library; disabling support for it.
* Could not find bzip2 headers and library; disabling support for it.
cythoning tables\linkExtension.pyx to tables\linkExtension.c
running install
running build
running build_py
running build_ext
No module named msvccompiler in numpy.distutils; trying from distutils
building 'tables.utilsExtension' extension
C:\Program Files\Microsoft Visual Studio 9.0\VC\BIN\cl.exe /c /nologo /Ox /MD /W
3 /GS- /DNDEBUG -DNDEBUG=1 -DWIN32=1 -D_HDF5USEDLL_=1 -Iblosc -IC:\Python27\lib\
site-packages\numpy-1.6.2-py2.7-win32.egg\numpy\core\include -I"C:\Program Files
\HDF Group\HDF5\1.8.9\include" -IC:\Python27\include -IC:\Python27\PC /Tctables\
utilsExtension.c /Fobuild\temp.win32-2.7\Release\tables\utilsExtension.obj -Isrc
-DH5_USE_16_API
Found executable C:\Program Files\Microsoft Visual Studio 9.0\VC\BIN\cl.exe
utilsExtension.c
c:\program files\hdf group\hdf5\1.8.9\include\H5public.h(47) : fatal error C1083
: Не удается открыть файл include: stdint.h: No such file or directory
error: Command "C:\Program Files\Microsoft Visual Studio 9.0\VC\BIN\cl.exe /c /n
ologo /Ox /MD /W3 /GS- /DNDEBUG -DNDEBUG=1 -DWIN32=1 -D_HDF5USEDLL_=1 -Iblosc -I
C:\Python27\lib\site-packages\numpy-1.6.2-py2.7-win32.egg\numpy\core\include -I"
C:\Program Files\HDF Group\HDF5\1.8.9\include" -IC:\Python27\include -IC:\Python
27\PC /Tctables\utilsExtension.c /Fobuild\temp.win32-2.7\Release\tables\utilsExt
ension.obj -Isrc -DH5_USE_16_API" failed with exit status 2

Installing Python packages with C extensions from source on Windows is difficult. Luckily, there are people who build these kits and make them available: http://www.lfd.uci.edu/~gohlke/pythonlibs/#pytables
Install it from a binary kit, you'll be much happier.

Possible duplicate: pytables installation failed
Check out this answer:
https://stackoverflow.com/a/68740234/11236901
Or just install a stable version for your os from: http://www.lfd.uci.edu/~gohlke/pythonlibs/#pytables
And install the file in your directory with:
pip install C:/some-dir/some-file.whl

Related

unknown error installing scrapy in pycharm on windows 10

I'm trying to install scrapy in my project virtual environnement in pycharm and i'm having the following error. ( this is the last few lines of the error log it is quite long )
I don't know what is wrong or what to look for.
I tried to install it using the package manager and the pip install scrapy command and the result is the same.
can you help me? thank you and have a nice day!
building 'twisted.test.raiser' extension
creating build\temp.win32-3.8
creating build\temp.win32-3.8\Release
creating build\temp.win32-3.8\Release\src
creating build\temp.win32-3.8\Release\src\twisted
creating build\temp.win32-3.8\Release\src\twisted\test
C:\Program Files (x86)\Microsoft Visual Studio\2019\Community\VC\Tools\MSVC\14.24.28314\bin\HostX86\x86\cl.exe /c /nologo /Ox /W3 /GL /DNDEBUG /MD -DWIN32=1 -IC:\Users\XXXXX\PycharmProjects\scrapicerie\venv\include -IC:\Python\Python38-32\include -IC:\Python\Python38-32\include "-IC:\Program Files (x86)\Microsoft Visual Studio\2019\Community\VC\Tools\MSVC\14.24.28314\include" /Tcsrc/twisted/test/raiser.c /Fobuild\temp.win32-3.8\Release\src/twisted/test/raiser.obj
raiser.c
C:\Python\Python38-32\include\pyconfig.h(59): fatal error C1083: Impossible d'ouvrir le fichier includeÿ: 'io.h'ÿ: No such file or directory
error: command 'C:\\Program Files (x86)\\Microsoft Visual Studio\\2019\\Community\\VC\\Tools\\MSVC\\14.24.28314\\bin\\HostX86\\x86\\cl.exe' failed with exit status 2
----------------------------------------
Apparently it had something to do with visual studio.
I reinstalled visual studio with the python and c++ module and now scrapy installed correctly in pycharm.

installing pyGObject has an error in pycharm

while i'm trying to install pyGObject in my Pycharm. it does not work. and has an error :
error: command '"C:\Program Files (x86)\Microsoft Visual Studio 10.0\VC\Bin\x86_amd64\cl.exe"' failed with exit status 2]
and the output command :
running build_ext
building 'cairo._cairo' extension
creating build\temp.win-amd64-3.4
creating build\temp.win-amd64-3.4\Release
creating build\temp.win-amd64-3.4\Release\cairo
C:\Program Files (x86)\Microsoft Visual Studio 10.0\VC\Bin\x86_amd64\cl.exe /c /nologo /Ox /MD /W3 /GS- /DNDEBUG -DPYCAIRO_VERSION_MAJOR=1 -DPYCAIRO_VERSION_MINOR=18 -DPYCAIRO_VERSION_MICRO=0 -IC:\Users\asus\PycharmProjects\Testt\venv\include -IC:\Python34\include -IC:\Python34\include /Tccairo/device.c /Fobuild\temp.win-amd64-3.4\Release\cairo/device.obj
device.c
c:\users\asus\appdata\local\temp\pycharm-packaging\pycairo\cairo\pycairo.h(37) : fatal error C1083: Cannot open include file: 'cairo.h': No such file or directory
error: command '"C:\Program Files (x86)\Microsoft Visual Studio 10.0\VC\Bin\x86_amd64\cl.exe"' failed with exit status 2
----------------------------------------
my python version is 3.4.8 and working in windows 8.1

Quantlib-SWIG 1.12.x for Python error, missing Quantlib/quantlib_wrap.cpp in windows

I downloaded both Quantlib-SWIG 1.12.x and Quantlib 1.12.x from github. Quantlib is compiled without and problems. The examples ran normally. However, when run python setup.py build, there is an error indicating missing quantlib_wrap.cpp. Where to download the proper quantlib_wrap.cpp for this version or this error is related to something else? Here is the messages I got from this build.
C:\Users\Public\3rdParty\Libraries\QuantLib-SWIG-1.12.x\Python>python setup.py build
running build
running build_py
file QuantLib\QuantLib.py (for module QuantLib.QuantLib) not found
file QuantLib\QuantLib.py (for module QuantLib.QuantLib) not found
running build_ext
building 'QuantLib._QuantLib' extension
C:\Users\U435169\AppData\Local\Programs\Common\Microsoft\Visual C++ for Python\9.0\VC\Bin\cl.exe /c /nologo /Ox /MD /W3 /GS- /DNDEBUG -D__WIN32__ -DWIN32 -DNDEBUG -D_WINDOWS -DNOMINMAX -Id:\packages\Python27\include -Id:\packages\Python27\PC -IC:\Users\Public\3rdParty\Libraries\QuantLib-master /TpQuantLib/quantlib_wrap.cpp /Fobuild\temp.win32-2.7\Release\QuantLib/quantlib_wrap.obj /GR /FD /Zm250 /EHsc /bigobj /MD
quantlib_wrap.cpp
c1xx : fatal error C1083: Cannot open source file: 'QuantLib/quantlib_wrap.cpp': No such file or directory
error: command 'C:\\Users\\U435169\\AppData\\Local\\Programs\\Common\\Microsoft\\Visual C++ for Python\\9.0\\VC\\Bin\\cl.exe' failed with exit status 2
quantlib_wrap.cpp is generated by SWIG using the sources in the repository. If you have SWIG installed, you can generate it (see https://www.quantlib.org/install/windows-python.shtml); but if you don't have plans to modify the sources, I suggest that you either:
instead of cloning the repo from GitHub, download an official release (see https://www.quantlib.org/download.shtml); released sources include quantlib_wrap.cpp;
or better yet, as suggested in the install page linked above, try running
pip install QuantLib-Python
to see if a precompiled Python module is available from PyPI. If that succeeds, you'll be set without having to compile the thing yourself.

error while building mysqlclient on windows

everyone ! I am facing the below issue when I ran the command : python setup.py build inside the mysqlclient directory. I have installed mysqlclient 1.3.7
Do you have any solution to fix this ? I am trying to setup MySQL with django.
C:\Users\Hp\Downloads\Compressed\mysqlclient-1.3.7\mysqlclient-1.3.7>python setu
p.py build
running build
running build_py
copying MySQLdb\release.py -> build\lib.win32-3.4\MySQLdb
running build_ext
building '_mysql' extension
C:\Program Files (x86)\Microsoft Visual Studio 10.0\VC\BIN\cl.exe /c /nologo /Ox
/MD /W3 /GS- /DNDEBUG -Dversion_info=(1,3,7,'final',1) -D__version__=1.3.7 "-IC
:\Program Files (x86)\MySQL\MySQL Connector C 6.1\include" -IC:\Python34\include
-IC:\Python34\include /Tc_mysql.c /Fobuild\temp.win32-3.4\Release\_mysql.obj /Z
l
_mysql.c
_mysql.c(29) : fatal error C1083: Cannot open include file: 'my_config.h': No su
ch file or directory
error: command 'C:\\Program Files (x86)\\Microsoft Visual Studio 10.0\\VC\\BIN\\
cl.exe' failed with exit status 2
C:\Users\Hp\Downloads\Compressed\mysqlclient-1.3.7\mysqlclient-1.3.7>python setu
p.py install
running install
running bdist_egg
running egg_info
writing top-level names to mysqlclient.egg-info\top_level.txt
writing dependency_links to mysqlclient.egg-info\dependency_links.txt
writing mysqlclient.egg-info\PKG-INFO
reading manifest file 'mysqlclient.egg-info\SOURCES.txt'
reading manifest template 'MANIFEST.in'
writing manifest file 'mysqlclient.egg-info\SOURCES.txt'
installing library code to build\bdist.win32\egg
running install_lib
running build_py
copying MySQLdb\release.py -> build\lib.win32-3.4\MySQLdb
running build_ext
building '_mysql' extension
C:\Program Files (x86)\Microsoft Visual Studio 10.0\VC\BIN\cl.exe /c /nologo /Ox
/MD /W3 /GS- /DNDEBUG -Dversion_info=(1,3,7,'final',1) -D__version__=1.3.7 "-IC
:\Program Files (x86)\MySQL\MySQL Connector C 6.1\include" -IC:\Python34\include
-IC:\Python34\include /Tc_mysql.c /Fobuild\temp.win32-3.4\Release\_mysql.obj /Z
l
_mysql.c
_mysql.c(29) : fatal error C1083: Cannot open include file: 'my_config.h': No su
ch file or directory
error: command 'C:\\Program Files (x86)\\Microsoft Visual Studio 10.0\\VC\\BIN\\
cl.exe' failed with exit status 2
Try to install it via pip
pip install mysqlclient
If you want to build it from source you need to get mysql source as well. Follow this link to find proper source to download.

can't import python extension

I'm trying to learn python extensions, and I created the simple noddy example c file and setup.py.
python.exe setup.py build gives me:
running build
running build_ext
building 'noddy' extension
creating build
creating build\temp.win32-2.7
creating build\temp.win32-2.7\Release
C:\Program Files\Microsoft Visual Studio 8\VC\BIN\cl.exe /c /nologo /Ox /MD /W3 /GS- /DNDEBUG -IC:\python27\include -IC:\python27\PC /Tcnoddy.c /Fobuild\temp.win32-2.7\Release\noddy.obj
noddy.c
creating build\lib.win32-2.7
C:\Program Files\Microsoft Visual Studio 8\VC\BIN\link.exe /DLL /nologo /INCREMENTAL:NO /LIBPATH:C:\python27\libs /LIBPATH:C:\python27\PCbuild /EXPORT:initnoddy build\temp.win32-2.7\Release\noddy.obj /OUT:build\lib.win32-2.7\noddy.pyd /IMPLIB:build\temp.win32-2.7\Release\noddy.lib /MANIFESTFILE:build\temp.win32-2.7\Release\noddy.pyd.manifest
Creating library build\temp.win32-2.7\Release\noddy.lib and object build\temp.win32-2.7\Release\noddy.exp
C:\Program Files\Microsoft Visual Studio 8\VC\BIN\mt.exe -nologo -manifest build\temp.win32-2.7\Release\noddy.pyd.manifest -outputresource:build\lib.win32-2.7\noddy.pyd;2
I then run python.exe setup.py install, which gives me:
running install
running build
running build_ext
running install_lib
copying build\lib.win32-2.7\noddy.pyd -> C:\python27\Lib\site-packages
running install_egg_info
Writing C:\python27\Lib\site-packages\noddy-1.0-py2.7.egg-info
But then, in Idle,
>>> import noddy
Traceback (most recent call last):
File "<pyshell#0>", line 1, in <module>
import noddy
ImportError: DLL load failed: The specified module could not be found.
So, what am I doing wrong? Admittedly, I am horribly confused.
Use the Visual Studio 2008 compiler to build the module.
VS8 is Visual Studio 2005 and the modules compiled with that version are incompatible with Python 2.7 (same applies to modules compiled with Visual Studio 2010 btw.).

Categories

Resources