I'm trying to install functools using pip. But i'm getting following error.
Collecting functools
Using cached functools-0.5.tar.gz
Building wheels for collected packages: functools
Running setup.py bdist_wheel for functools ... error
Complete output from command c:\python35\python.exe -u -c "import setuptools, tokenize;__file__='C:\\Users\\TAUSEE~1\\AppData\\Local\\Temp\\pip-build-0gc470iw\\functools\\setup.py';f=getattr(tokenize, 'open', open)(__file__);code=f.read().replace('\r\n', '\n');f.close();exec(compile(code, __file__, 'exec'))" bdist_wheel -d C:\Users\TAUSEE~1\AppData\Local\Temp\tmpn0sob7vxpip-wheel- --python-tag cp35:
running bdist_wheel
running build
running build_py
creating build
creating build\lib.win-amd64-3.5
copying functools.py -> build\lib.win-amd64-3.5
running build_ext
building '_functools' extension
creating build\temp.win-amd64-3.5
creating build\temp.win-amd64-3.5\Release
creating build\temp.win-amd64-3.5\Release\src
C:\Program Files (x86)\Microsoft Visual Studio 14.0\VC\BIN\x86_amd64\cl.exe /c /nologo /Ox /W3 /GL /DNDEBUG /MD -Ic:\python35\include -Ic:\python35\include "-IC:\Program Files (x86)\Microsoft Visual Studio 14.0\VC\INCLUDE" "-IC:\Program Files (x86)\Microsoft Visual Studio 14.0\VC\ATLMFC\INCLUDE" "-IC:\Program Files (x86)\Windows Kits\10\include\10.0.10240.0\ucrt" "-IC:\Program Files (x86)\Windows Kits\NETFXSDK\4.6.1\include\um" "-IC:\Program Files (x86)\Windows Kits\10\include\10.0.10240.0\shared" "-IC:\Program Files (x86)\Windows Kits\10\include\10.0.10240.0\um" "-IC:\Program Files (x86)\Windows Kits\10\include\10.0.10240.0\winrt" /Tcsrc\functools.c /Fobuild\temp.win-amd64-3.5\Release\src\functools.obj
functools.c
src\functools.c(43): warning C4013: 'Py_InitModule3' undefined; assuming extern returning int
src\functools.c(43): warning C4047: '=': 'PyObject *' differs in levels of indirection from 'int'
src\functools.c(45): warning C4033: 'init_functools' must return a value
src\functools.c(49): warning C4033: 'init_functools' must return a value
C:\Program Files (x86)\Microsoft Visual Studio 14.0\VC\BIN\x86_amd64\cl.exe /c /nologo /Ox /W3 /GL /DNDEBUG /MD -Ic:\python35\include -Ic:\python35\include "-IC:\Program Files (x86)\Microsoft Visual Studio 14.0\VC\INCLUDE" "-IC:\Program Files (x86)\Microsoft Visual Studio 14.0\VC\ATLMFC\INCLUDE" "-IC:\Program Files (x86)\Windows Kits\10\include\10.0.10240.0\ucrt" "-IC:\Program Files (x86)\Windows Kits\NETFXSDK\4.6.1\include\um" "-IC:\Program Files (x86)\Windows Kits\10\include\10.0.10240.0\shared" "-IC:\Program Files (x86)\Windows Kits\10\include\10.0.10240.0\um" "-IC:\Program Files (x86)\Windows Kits\10\include\10.0.10240.0\winrt" /Tcsrc\compose.c /Fobuild\temp.win-amd64-3.5\Release\src\compose.obj
compose.c
src\compose.c(57): warning C4244: '=': conversion from 'Py_ssize_t' to 'int', possible loss of data
src\compose.c(96): error C2039: 'ob_type': is not a member of 'compose'
src\compose.c(44): note: see declaration of 'compose'
src\compose.c(137): warning C4013: 'PyString_FromFormat' undefined; assuming extern returning int
src\compose.c(138): warning C4013: 'PyString_AsString' undefined; assuming extern returning int
src\compose.c(138): warning C4047: '=': 'PyObject *' differs in levels of indirection from 'int'
src\compose.c(143): warning C4047: 'initializing': 'Py_ssize_t' differs in levels of indirection from 'char [8]'
src\compose.c(143): warning C4113: 'destructor' differs in parameter lists from 'printfunc'
src\compose.c(143): warning C4133: 'initializing': incompatible types - from 'destructor' to 'printfunc'
src\compose.c(143): warning C4047: 'initializing': 'PyNumberMethods *' differs in levels of indirection from 'reprfunc'
src\compose.c(143): warning C4113: 'ternaryfunc' differs in parameter lists from 'reprfunc'
src\compose.c(143): warning C4047: 'initializing': 'const char *' differs in levels of indirection from 'unsigned long'
src\compose.c(143): warning C4047: 'initializing': 'traverseproc' differs in levels of indirection from 'char *'
src\compose.c(143): warning C4113: 'traverseproc' differs in parameter lists from 'inquiry'
src\compose.c(143): warning C4113: 'PyObject *(__cdecl *)(PyObject *,PyObject *)' differs in parameter lists from 'descrsetfunc'
src\compose.c(143): warning C4047: 'initializing': 'descrsetfunc' differs in levels of indirection from 'PyObject *(__cdecl *)(PyObject *,PyObject *)'
src\compose.c(143): warning C4113: 'PyObject *(__cdecl *)(PyTypeObject *,PyObject *,PyObject *)' differs in parameter lists from 'freefunc'
src\compose.c(143): warning C4047: 'initializing': 'freefunc' differs in levels of indirection from 'PyObject *(__cdecl *)(PyTypeObject *,PyObject *,PyObject *)'
src\compose.c(143): warning C4133: 'initializing': incompatible types - from 'void (__cdecl *)(void *)' to 'inquiry'
error: command 'C:\\Program Files (x86)\\Microsoft Visual Studio 14.0\\VC\\BIN\\x86_amd64\\cl.exe' failed with exit status 2
----------------------------------------
Failed building wheel for functools
Running setup.py clean for functools
Failed to build functools
Installing collected packages: functools
Running setup.py install for functools ... error
Complete output from command c:\python35\python.exe -u -c "import setuptools, tokenize;__file__='C:\\Users\\TAUSEE~1\\AppData\\Local\\Temp\\pip-build-0gc470iw\\functools\\setup.py';f=getattr(tokenize, 'open', open)(__file__);code=f.read().replace('\r\n', '\n');f.close();exec(compile(code, __file__, 'exec'))" install --record C:\Users\TAUSEE~1\AppData\Local\Temp\pip-z68u1oc7-record\install-record.txt --single-version-externally-managed --compile:
running install
running build
running build_py
creating build
creating build\lib.win-amd64-3.5
copying functools.py -> build\lib.win-amd64-3.5
running build_ext
building '_functools' extension
creating build\temp.win-amd64-3.5
creating build\temp.win-amd64-3.5\Release
creating build\temp.win-amd64-3.5\Release\src
C:\Program Files (x86)\Microsoft Visual Studio 14.0\VC\BIN\x86_amd64\cl.exe /c /nologo /Ox /W3 /GL /DNDEBUG /MD -Ic:\python35\include -Ic:\python35\include "-IC:\Program Files (x86)\Microsoft Visual Studio 14.0\VC\INCLUDE" "-IC:\Program Files (x86)\Microsoft Visual Studio 14.0\VC\ATLMFC\INCLUDE" "-IC:\Program Files (x86)\Windows Kits\10\include\10.0.10240.0\ucrt" "-IC:\Program Files (x86)\Windows Kits\NETFXSDK\4.6.1\include\um" "-IC:\Program Files (x86)\Windows Kits\10\include\10.0.10240.0\shared" "-IC:\Program Files (x86)\Windows Kits\10\include\10.0.10240.0\um" "-IC:\Program Files (x86)\Windows Kits\10\include\10.0.10240.0\winrt" /Tcsrc\functools.c /Fobuild\temp.win-amd64-3.5\Release\src\functools.obj
functools.c
src\functools.c(43): warning C4013: 'Py_InitModule3' undefined; assuming extern returning int
src\functools.c(43): warning C4047: '=': 'PyObject *' differs in levels of indirection from 'int'
src\functools.c(45): warning C4033: 'init_functools' must return a value
src\functools.c(49): warning C4033: 'init_functools' must return a value
C:\Program Files (x86)\Microsoft Visual Studio 14.0\VC\BIN\x86_amd64\cl.exe /c /nologo /Ox /W3 /GL /DNDEBUG /MD -Ic:\python35\include -Ic:\python35\include "-IC:\Program Files (x86)\Microsoft Visual Studio 14.0\VC\INCLUDE" "-IC:\Program Files (x86)\Microsoft Visual Studio 14.0\VC\ATLMFC\INCLUDE" "-IC:\Program Files (x86)\Windows Kits\10\include\10.0.10240.0\ucrt" "-IC:\Program Files (x86)\Windows Kits\NETFXSDK\4.6.1\include\um" "-IC:\Program Files (x86)\Windows Kits\10\include\10.0.10240.0\shared" "-IC:\Program Files (x86)\Windows Kits\10\include\10.0.10240.0\um" "-IC:\Program Files (x86)\Windows Kits\10\include\10.0.10240.0\winrt" /Tcsrc\compose.c /Fobuild\temp.win-amd64-3.5\Release\src\compose.obj
compose.c
src\compose.c(57): warning C4244: '=': conversion from 'Py_ssize_t' to 'int', possible loss of data
src\compose.c(96): error C2039: 'ob_type': is not a member of 'compose'
src\compose.c(44): note: see declaration of 'compose'
src\compose.c(137): warning C4013: 'PyString_FromFormat' undefined; assuming extern returning int
src\compose.c(138): warning C4013: 'PyString_AsString' undefined; assuming extern returning int
src\compose.c(138): warning C4047: '=': 'PyObject *' differs in levels of indirection from 'int'
src\compose.c(143): warning C4047: 'initializing': 'Py_ssize_t' differs in levels of indirection from 'char [8]'
src\compose.c(143): warning C4113: 'destructor' differs in parameter lists from 'printfunc'
src\compose.c(143): warning C4133: 'initializing': incompatible types - from 'destructor' to 'printfunc'
src\compose.c(143): warning C4047: 'initializing': 'PyNumberMethods *' differs in levels of indirection from 'reprfunc'
src\compose.c(143): warning C4113: 'ternaryfunc' differs in parameter lists from 'reprfunc'
src\compose.c(143): warning C4047: 'initializing': 'const char *' differs in levels of indirection from 'unsigned long'
src\compose.c(143): warning C4047: 'initializing': 'traverseproc' differs in levels of indirection from 'char *'
src\compose.c(143): warning C4113: 'traverseproc' differs in parameter lists from 'inquiry'
src\compose.c(143): warning C4113: 'PyObject *(__cdecl *)(PyObject *,PyObject *)' differs in parameter lists from 'descrsetfunc'
src\compose.c(143): warning C4047: 'initializing': 'descrsetfunc' differs in levels of indirection from 'PyObject *(__cdecl *)(PyObject *,PyObject *)'
src\compose.c(143): warning C4113: 'PyObject *(__cdecl *)(PyTypeObject *,PyObject *,PyObject *)' differs in parameter lists from 'freefunc'
src\compose.c(143): warning C4047: 'initializing': 'freefunc' differs in levels of indirection from 'PyObject *(__cdecl *)(PyTypeObject *,PyObject *,PyObject *)'
src\compose.c(143): warning C4133: 'initializing': incompatible types - from 'void (__cdecl *)(void *)' to 'inquiry'
error: command 'C:\\Program Files (x86)\\Microsoft Visual Studio 14.0\\VC\\BIN\\x86_amd64\\cl.exe' failed with exit status 2
I had this error before while installing resampy and I solved it by installing VS build tools. I also added vcvarsal.bat file to variable path and resampy was finally installed. But functools doesn't seem to install. Neither can I find wheel for it. I have pasted the entire message that I get after executing pip install functools
I'm using python 3.5.3 win10 x64
Would appreciate any help on this issue.
The last update for the functools on python package index isfrom 2005. As explained on this SO, it's been included into the standard library since python 2.7