I am getting an error while trying pip install DAG packcage.
Error
Collecting DAG
Using cached https://files.pythonhosted.org/packages/e1/92/ffc722ac557e3c180f8ec6cdad96d2731b981677529c263c3df04a656910/DAG-0.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\ASHOK~1.EAP\AppData\Local\Temp\pip-install-4dybsujd\DAG\setup.py", line 1, in <module>
from ez_setup import use_setuptools
File "C:\Users\ASHOK~1.EAP\AppData\Local\Temp\pip-install-4dybsujd\DAG\ez_setup.py", line 94
except pkg_resources.VersionConflict, e:
^
SyntaxError: invalid syntax
----------------------------------------
Command "python setup.py egg_info" failed with error code 1 in C:\Users\ASHOK~1.EAP\AppData\Local\Temp\pip-install-4dybsujd\DAG\
How to fix this.
Try pip install py-dag, this will use https://github.com/thieman/py-dag
DAG, released in 2007. The code is Python2-only.
Try installing the module with Python 2.7. Or find a different, Python3-compatible module.
Related
I'm to trying create a project in Python using Django. One of the dependencies is a connection with Mysql. I'm Using pip to import whatever I need.
My problem is the error when I run this line: sudo pip3 install mysql-python
The return is:
Collecting mysql-python
Using cached https://files.pythonhosted.org/packages/a5/e9/51b544da85a36a68debe7a7091f068d802fc515a3a202652828c73453cad/MySQL-python-1.2.5.zip
Complete output from command python setup.py egg_info:
Traceback (most recent call last):
File "<string>", line 1, in <module>
File "/tmp/pip-install-6dok9yt5/mysql-python/setup.py", line 13, in <module>
from setup_posix import get_config
File "/tmp/pip-install-6dok9yt5/mysql-python/setup_posix.py", line 2, in <module>
from ConfigParser import SafeConfigParser
ModuleNotFoundError: No module named 'ConfigParser'
The final line is: Command "python setup.py egg_info" failed with error code 1 in /tmp/pip-install-6dok9yt5/mysql-python/
Someone can help me? Thanks in advance!
As far as I know "mysql-python" currently does not support python3
MySQL-3.23 through 5.5 and Python-2.4 through 2.7 are currently supported. Python-3.0 will be supported in a future release. PyPy is supported.
Maybe this will help:
https://stackoverflow.com/a/25724855/966660
I've created a Django project and its works as well now I'm trying to config it with MySql so searched in Google and did some ways but when I pip install MySQL-python the below problem occurs:
Collecting MySQL-python
Using cached MySQL-python-1.2.5.zip
Complete output from command python setup.py egg_info:
Traceback (most recent call last):
File "<string>", line 1, in <module>
File "/tmp/pip-build-lwubgejh/MySQL-python/setup.py", line 13, in <module>
from setup_posix import get_config
File "/tmp/pip-build-lwubgejh/MySQL-python/setup_posix.py", line 2, in <module>
from ConfigParser import SafeConfigParser
ImportError: No module named 'ConfigParser'
----------------------------------------
Command "python setup.py egg_info" failed with error code 1 in /tmp/pip-build-lwubgejh/MySQL-python/
couldn't find any solution for this error:
Command "python setup.py egg_info" failed with error code 1 in /tmp/pip-build-lwubgejh/MySQL-python/
thank you for help.
This library is not compatible with Python 3. Follow the advice in the Django docs and install mysqlclient instead.
Extracting in C:\Users\hkpra\AppData\Local\Temp\tmp3esvodcb
Traceback (most recent call last):
File "c:\program files\python35\lib\site-packages\ez_setup.py", line 143, in use_setuptools
raise ImportError
ImportError
During handling of the above exception, another exception occurred:
Traceback (most recent call last):
File "<string>", line 1, in <module>
File "C:\Users\hkpra\AppData\Local\Temp\pip-build-imphcwak\unroll\setup.py", line 2, in <module>
ez_setup.use_setuptools()
File "c:\program files\python35\lib\site-packages\ez_setup.py", line 145, in use_setuptools
return _do_download(version, download_base, to_dir, download_delay)
File "c:\program files\python35\lib\site-packages\ez_setup.py", line 125, in _do_download
_build_egg(egg, tarball, to_dir)
File "c:\program files\python35\lib\site-packages\ez_setup.py", line 99, in _build_egg
_extractall(tar)
File "c:\program files\python35\lib\site-packages\ez_setup.py", line 467, in _extractall
self.chown(tarinfo, dirpath)
TypeError: chown() missing 1 required positional argument: 'numeric_owner'
----------------------------------------
Command "python setup.py egg_info" failed with error code 1 in C:\Users\hkpra\AppData\Local\Temp\pip-build-imphcwak\unroll\
These are the things you need to do to fix this error when installing python. Make sure to follow in accordance.
check if PIP and setuptools are installed.
upgrade PIP and setuptools.
install ez_setup.
Should you want step by step guidance on how to go about it, you can go here.
install python again, then successed
I also install by pip,lick
pip install locustio
or
sudo pip install locustio
but error occur
Collecting locustio
Using cached locustio-0.7.5.tar.gz
Complete output from command python setup.py egg_info:
running egg_info
error: Invalid distribution name or version syntax: locustio-0.7.5
Command "python setup.py egg_info" failed with error code 1 in /private/var/folders/yw/15gswkd13v37xjqjy66rc8xc0000gn/T/pip-build-hFFjxs/locustio/
I try pip, pip3, and so on. Finally, I install python again and then it is ok.
for python2.7
sudo pip install python
for python3
sudo pip install python3
I am trying to install python module Flask-Spyne on Windows and when I type pip install Flask-Spyne, on Sec-Wall collecting TypeError appear.
I am using Python 3.5.1 on Windows 10
This is it:
C:\Windows\system32>pip install flask-spyne
Collecting flask-spyne
Using cached Flask-Spyne-0.2.tar.gz
Collecting flask (from flask-spyne)
Using cached Flask-0.11.1-py2.py3-none-any.whl
Collecting spyne (from flask-spyne)
Using cached spyne-2.12.11.tar.gz
Collecting sec-wall (from flask-spyne)
Using cached sec-wall-1.2.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\SIVK~1\AppData\Local\Temp\pip-build-mydzld6p\sec-wall\setup.py", line 30, in <module>
packages = find_packages(b"src"),
File "c:\program files (x86)\python35-32\lib\site-packages\setuptools\__init__.py", line 51, in find
out = cls._find_packages_iter(convert_path(where))
File "c:\program files (x86)\python35-32\lib\distutils\util.py", line 129, in convert_path
paths = pathname.split('/')
TypeError: a bytes-like object is required, not 'str'
----------------------------------------
Command "python setup.py egg_info" failed with error code 1 in C:\Users\SIVK~1\AppData\Local\Temp\pip-build-mydzld6p\sec-wall\
I tried solve python setup.py egg_info error, nothing.
I tried to look at that TypeError, nothing.
Does someone know how to solve it? For any advice I am happy :)
PS: If it help, that when I type pip install suds, this appear:
C:\Windows\system32>pip install suds
Collecting suds
Using cached suds-0.4.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\SIVK~1\AppData\Local\Temp\pip-build-l7jpgeg4\suds\setup.py", line 20, in <module>
import suds
File "C:\Users\SIVK~1\AppData\Local\Temp\pip-build-l7jpgeg4\suds\suds\__init__.py", line 154, in <module>
import client
ImportError: No module named 'client'
----------------------------------------
Command "python setup.py egg_info" failed with error code 1 in C:\Users\SIVK~1\AppData\Local\Temp\pip-build-l7jpgeg4\suds\
According to Spyne's documentation, it's known to work with Python versions 2.6. and 2.7, but Python 3 support is not tested.
Also, the error you've got TypeError: a bytes-like object is required, not 'str' is what people often experience when migrating their code from python 2.7 to python 3.
I can reproduce your error when installing the package for python 3.5. And I got no errors when installing it for Python 2.7.
So, maybe you have to switch to Python 2.7, and/or report the problem to the package's developer.
I am having problems with importing tweedy:
this is the error received
Traceback (most recent call last):
File "star_twitter.py", line 71, in <module>
send_to_twitter(get_price())
File "star_twitter.py", line 9, in send_to_twitter
import tweepy
ImportError: No module named tweepy
I tried re-installing it but now am receiving the following error message
Downloading/unpacking tweepy
Downloading tweepy-3.3.0.tar.gz
Running setup.py egg_info for package tweepy
Traceback (most recent call last):
File "<string>", line 14, in <module>
File "/home/pi/build/tweepy/setup.py", line 17, in <module>
install_reqs = parse_requirements('requirements.txt', session=uuid.uuid1())
TypeError: parse_requirements() got an unexpected keyword argument 'session'
Complete output from command python setup.py egg_info:
Traceback (most recent call last):
File "<string>", line 14, in <module>
File "/home/pi/build/tweepy/setup.py", line 17, in <module>
install_reqs = parse_requirements('requirements.txt', session=uuid.uuid1())
TypeError: parse_requirements() got an unexpected keyword argument 'session'
----------------------------------------
Command python setup.py egg_info failed with error code 1 in /home/pi/build/tweepy
Storing complete log in /root/.pip/pip.log
Your assistance will be appreciated
You may have faced known problem. Try upgrading pip.
sudo pip install --upgrade pip
The fact that you're using virtualenv does help. If you used sudo trying to install tweepy then that's where the installation went wrong.
Try using pip install tweepy only.
If you're still getting an error from that then your virtualenv has probably became corrup. Do the following:
$ deactivate
$ rmvirtualenv nlmanagement
$ mkvirtualenv nlmanagement
$ pip install -r requirements.txt
Try the pip installation first and only use that for future needs in virtualenv.