I use command 'pip install tables' in powershell (Windows) to install Pytables. Yet I receive the ValueError: [u'path'].
In red is written 'Command "python setup.py egg_info" failed with error code 1'.
I have miniconda installed.
EDIT: the full red error message is the following:
'Command "python setup.py egg_info" failed with error code 1 in c:\users\evert\appdata\local\temp\pip-build-9wkucl\tables
\'
Between my pip install command and the red error message is written the following:
Collecting tables
Using cached tables-3.2.2.tar.gz
Complete output from command python setup.py egg_info:
* Using Python 2.7.11 |Continuum Analytics, Inc.| (default, Feb 16 2016, 09:58:36) [MSC v.1500 64 bit (AMD64)]
* USE_PKGCONFIG: False
Traceback (most recent call last):
File "<string>", line 1, in <module>
File "c:\users\evert\appdata\local\temp\pip-build-9wkucl\tables\setup.py", line 553, in <module>
libraries=(package.library_name,))
File "c:\users\evert\miniconda2\lib\distutils\ccompiler.py", line 758, in has_function
objects = self.compile([fname], include_dirs=include_dirs)
File "c:\users\evert\miniconda2\lib\distutils\msvc9compiler.py", line 473, in compile
self.initialize()
File "c:\users\evert\miniconda2\lib\distutils\msvc9compiler.py", line 383, in initialize
vc_env = query_vcvarsall(VERSION, plat_spec)
File "c:\users\evert\miniconda2\lib\site-packages\setuptools-20.3-py2.7.egg\setuptools\msvc9_support.py", line 52,
in query_vcvarsall
File "c:\users\evert\miniconda2\lib\distutils\msvc9compiler.py", line 299, in query_vcvarsall
raise ValueError(str(list(result.keys())))
ValueError: [u'path']
Which part is missing? Which steps should I execute before running 'pip install tables'?
Thank you for your help.
This is a problem with not being able to correctly setup certain environment variables required for the setup using vcvarsall.bat. You can download a binary of pytables here instead and do pip install tables-3.2.2-*.whl. Be sure to download the binary matching your version and system architecture.
Related
Iam trying to install OCPP in Python 2.7 using following command and getting the error shown below. plz help to resolve the issue
C:\Python27>python -m pip install ocpp
Collecting ocpp
Downloading https://files.pythonhosted.org/packages/36/f8/f3222edf8cf0f1a7373c9d5b0be0974959b3cf302906f0c59fe8bf4071f7/ocpp-0.1.1.tar.gz
Complete output from command python setup.py egg_info:
Traceback (most recent call last):
File "<string>", line 1, in <module>
File "c:\users\vijaya~1\appdata\local\temp\pip-build-yaigdj\ocpp\setup.py", line 6, in <module>
with open(path.join(here, 'README.md'), encoding='utf-8') as f:
TypeError: 'encoding' is an invalid keyword argument for this function
----------------------------------------
Command "python setup.py egg_info" failed with error code 1 in c:\users\vijaya~1\appdata\local\temp\pip-build-yaigdj\ocpp\
You are using pip version 9.0.1, however version 20.2.4 is available.
You should consider upgrading via the 'python -m pip install --upgrade pip' command.
I installed python 3.8 and reinstalled OCPP. After that Iam trying to simulate the central system and charge point of PyPi OCPP given in the following link https://pypi.org/project/ocpp/. Central system code runs without any error. but while compiling the charge point code i am getting the following error
Python 3.8.3 (tags/v3.8.3:6f8c832, May 13 2020, 22:37:02) [MSC v.1924 64 bit (AMD64)] on win32
Type "help", "copyright", "credits" or "license()" for more information.
>>>
====================== RESTART: C:/Python38/ocppserver.py ======================
INFO:root:WebSocket Server Started
====================== RESTART: C:\Python38\chargepoint.py =====================
Traceback (most recent call last):
File "C:\Python38\chargepoint.py", line 39, in <module>
asyncio.run(main())
File "C:\Python38\lib\asyncio\runners.py", line 43, in run
return loop.run_until_complete(main)
File "C:\Python38\lib\asyncio\base_events.py", line 616, in run_until_complete
return future.result()
File "C:\Python38\chargepoint.py", line 28, in main
async with websockets.connect(
File "C:\Python38\lib\site-packages\websockets\client.py", line 517, in __aenter__
return await self
File "C:\Python38\lib\site-packages\websockets\client.py", line 535, in __await_impl__
transport, protocol = await self._create_connection()
File "C:\Python38\lib\asyncio\base_events.py", line 1030, in create_connection
raise exceptions[0]
File "C:\Python38\lib\asyncio\base_events.py", line 1010, in create_connection
sock = await self._connect_sock(
File "C:\Python38\lib\asyncio\base_events.py", line 924, in _connect_sock
await self.sock_connect(sock, address)
File "C:\Python38\lib\asyncio\proactor_events.py", line 702, in sock_connect
return await self._proactor.connect(sock, address)
File "C:\Python38\lib\asyncio\windows_events.py", line 808, in _poll
value = callback(transferred, key, ov)
File "C:\Python38\lib\asyncio\windows_events.py", line 595, in finish_connect
ov.getresult()
ConnectionRefusedError: [WinError 1225] The remote computer refused the network connection
>>>
[PyPI]: ocpp (currently v0.8.1) only supports Python 3. However, same thing applies to v0.1.1 (very 1st OCPP version).
So, the only way to proceed is install (and start using) Python 3, and give up Python 2(.7) (who is dead from the beginning of allmighty 2020 ([Python]: PEP 373 - Python 2.7 Release Schedule)).
Of course, there's the (painful) alternative of porting OCPP code to Python 2, but I'd totally advice against it.
I keep getting the error
Command "python setup.py egg_info" failed with error code 1 in C:\Users\HP\AppData\Local\Temp\pip-install-sv33cp8y\tables\
when trying to use
pip install tables
I've tried
pip install --upgrade setuptools
and quite a few other things but still can't get it to work.
The full error that I'm getting is:
Collecting tables
Using cached https://files.pythonhosted.org/packages/4d/53/8f34ce887c2a2ad80518980419a5f6f41defc85a287a355987e559ce9385/tables-3.4.4.tar.gz
Complete output from command python setup.py egg_info:
* Using Python 3.7.1 (v3.7.1:260ec2c36a, Oct 20 2018, 14:57:15) [MSC v.1915 64 bit (AMD64)]
* USE_PKGCONFIG: False
Traceback (most recent call last):
File "c:\python37\lib\site-packages\setuptools\msvc.py", line 489, in _find_latest_available_vc_ver
return self.find_available_vc_vers()[-1]
IndexError: list index out of range
During handling of the above exception, another exception occurred:
Traceback (most recent call last):
File "<string>", line 1, in <module>
File "C:\Users\HP\AppData\Local\Temp\pip-install-5bjrxgs8\tables\setup.py", line 633, in <module>
libraries=(package.library_name,))
File "c:\python37\lib\distutils\ccompiler.py", line 791, in has_function
objects = self.compile([fname], include_dirs=include_dirs)
File "c:\python37\lib\distutils\_msvccompiler.py", line 345, in compile
self.initialize()
File "c:\python37\lib\distutils\_msvccompiler.py", line 238, in initialize
vc_env = _get_vc_env(plat_spec)
File "c:\python37\lib\site-packages\setuptools\msvc.py", line 185, in msvc14_get_vc_env
return EnvironmentInfo(plat_spec, vc_min_ver=14.0).return_env()
File "c:\python37\lib\site-packages\setuptools\msvc.py", line 843, in __init__
self.si = SystemInfo(self.ri, vc_ver)
File "c:\python37\lib\site-packages\setuptools\msvc.py", line 485, in __init__
self.vc_ver = vc_ver or self._find_latest_available_vc_ver()
File "c:\python37\lib\site-packages\setuptools\msvc.py", line 492, in _find_latest_available_vc_ver
raise distutils.errors.DistutilsPlatformError(err)
distutils.errors.DistutilsPlatformError: Microsoft Visual C++ 14.0 is required. Get it with "Microsoft Visual C++ Build Tools": https://visualstudio.microsoft.com/downloads/
----------------------------------------
Command "python setup.py egg_info" failed with error code 1 in C:\Users\HP\AppData\Local\Temp\pip-install-5bjrxgs8\tables\
I'm basically trying to convert a hdf5 file into a csv and I just can't get it to work or anything at the moment.
Might be a permission issue.
Try :
sudo pip install --upgrade setuptools
Also refer to the discussion here. Some folks had this problem with python version.
I'm creating a tower defense game using python and pygame. I would like to add this one on the Google Play Store, but I need to create an apk file.
I'm following a tutorial on GitHub:
https://github.com/renpytom/rapt-pygame-example.
I follow all the instructions but can't install pygame_sdl2.
I use the command prompt, and use $ python setup.py install in the appropriate directory.
But it gave me this error :
C:\Users\gomes\Downloads\pygame_sdl2-master>python setup.py install
Traceback (most recent call last):
File "setup.py", line 59, in <module>
parse_cflags([ "sh", "-c", "sdl2-config --cflags" ])
File "C:\Users\gomes\Downloads\pygame_sdl2-master\setuplib.py", line 93, in parse_cflags
output = subprocess.check_output(command, universal_newlines=True)
File "C:\Python27\lib\subprocess.py", line 212, in check_output
process = Popen(stdout=PIPE, *popenargs, **kwargs)
File "C:\Python27\lib\subprocess.py", line 390, in __init__
errread, errwrite)
File "C:\Python27\lib\subprocess.py", line 640, in _execute_child
startupinfo)
WindowsError: [Error 2] Le fichier spÚcifiÚ est introuvable
I tried to reinstall pygame_sdl2-master, but gave me the same result.
You need the appropriate Windows dependencies and cython. I did some researching and testing and found this solution:
Install cython, type this in a terminal:
$ pip install cython
Go to your pygame_sdl2 directory and download the Windows dependencies by typing:
$ git clone https://github.com/renpy/pygame_sdl2_windeps
If it's not in the pygame_sdl2 directory, just move pygame_sdl2_windeps there manually.
Start building the library:
$ python setup.py install
I directly download pygame_sdl2_windeps on github. I have copied this one one the pygame_sdl2 directory and use the "python setup.py install" command in the command prompt, and IT WORKS !!!
C:\PGS4A\pygame_sdl2>python
Python 2.7.13 (v2.7.13:a06454b1afa1, Dec 17 2016, 20:42:59) [MSC v.1500 32 bit (Intel)] on win32
Type "help", "copyright", "credits" or "license" for more information.
>>> import pygame_sdl2
>>>
Thank you for your help !!!
OS: mac, El Capitan
Python version: 2.7.11
I tried to install shapely after setting up a brand new pyenv-virtualenv and changing my directory to use that 'pyenv version' and I get the following error:
dhcp-uris-1290:seam Chelsea$ pip install shapely
Collecting shapely
Using cached Shapely-1.5.15.tar.gz
Complete output from command python setup.py egg_info:
Traceback (most recent call last):
File "<string>", line 1, in <module>
File "/private/var/folders/1l/r_vh6y997rdgk6sdnkqsntpr0000gn/T/pip-build-odrxBR/shapely/setup.py", line 38, in <module>
from shapely._buildcfg import geos_version_string, geos_version, \
File "/private/var/folders/1l/r_vh6y997rdgk6sdnkqsntpr0000gn/T/pip-build-odrxBR/shapely/shapely/_buildcfg.py", line 88, in <module>
clibs = get_geos_config('--clibs')
File "/private/var/folders/1l/r_vh6y997rdgk6sdnkqsntpr0000gn/T/pip-build-odrxBR/shapely/shapely/_buildcfg.py", line 71, in get_geos_config
stdout=subprocess.PIPE, stderr=subprocess.PIPE).communicate()
File "/Users/Chelsea/.pyenv/versions/2.7.11/lib/python2.7/subprocess.py", line 710, in __init__
errread, errwrite)
File "/Users/Chelsea/.pyenv/versions/2.7.11/lib/python2.7/subprocess.py", line 1334, in _execute_child
child_exception = pickle.loads(data)
File "/Users/Chelsea/.pyenv/versions/2.7.11/lib/python2.7/pickle.py", line 1388, in loads
return Unpickler(file).load()
File "/Users/Chelsea/.pyenv/versions/2.7.11/lib/python2.7/pickle.py", line 864, in load
dispatch[key](self)
File "/Users/Chelsea/.pyenv/versions/2.7.11/lib/python2.7/pickle.py", line 972, in load_string
raise ValueError, "insecure string pickle"
ValueError: insecure string pickle
-----------------------------------------
Command "python setup.py egg_info" failed with error code 1 in /private/var/folders/1l/r_vh6y997rdgk6sdnkqsntpr0000gn/T/pip-build-odrxBR/shapely/
The whole reason I got into this virtualenv business is because I was getting insecure string pickle errors when trying to use matplotlib with system python on el capitan, which is known to be an issue (https://github.com/matplotlib/matplotlib/issues/5314) , so I tried to build my own new framework and run it, that didn't work, and now tried to set up a virtualenv but it looks like virtualenv might just not play nicely with certain python packages? :'(
Shapely install correctly OUTSIDE of a virtualenv on my machine, with system python. Sadly system python, as mentioned, was not playing nicely with matplotlib.
P.S. these are the packages I have installed in this particular pyenv-virtualenv:
cycler (0.10.0)
distribute (0.7.3)
matplotlib (1.5.1)
numpy (1.11.0)
pip (8.1.2)
pyparsing (2.1.4)
python-dateutil (2.5.3)
pytz (2016.4)
setuptools (21.1.0)
six (1.10.0)
wheel (0.29.0)
I have some trouble installing llvmpy on ubuntu 14.04, i downloaded llvmpy from llvmpy.org and installed llvm 3.4 via apt-get, when I try to install it using
python setup.py install
I get this error:
Error: could not invoke ['llvm-config', '--version']
Try setting LLVM_CONFIG_PATH=/path/to/llvm-config
Then i used
LLVM_CONFIG_PATH=/usr/lib/llvm-3.4/bin/llvm-config python setup.py install
and i got
LLVM version = u'3.4'
LLVM targets =
Generate intrinsic IDs
Searching shared library libLLVM-3.4 in /usr/lib/llvm-3.4/lib
Using dynamic linking
/usr/bin/python: can't open file 'llvmpy/build.py': [Errno 2] No such file or directory
Traceback (most recent call last):
File "setup.py", line 142, in <module>
check_call([sys.executable, 'llvmpy/build.py'])
File "/usr/lib/python2.7/subprocess.py", line 540, in check_call
raise CalledProcessError(retcode, cmd)
subprocess.CalledProcessError: Command '['/usr/bin/python',
'llvmpy/build.py']' returned non-zero exit status 2
How can I solve this?
If you got it from the tar.gz file available at https://pypi.python.org/packages/source/l/llvmpy/llvmpy-0.12.4.tar.gz , it is incomplete, try download as a zip from github https://github.com/llvmpy/llvmpy
Or directly via git commands