Installation problem on Debian Wheezy
Closed this issue · 6 comments
From an out of the box Debian 7 installation.
Install with Pip:
~/install/install036-zerobin$ sudo pip install zerobin
Downloading/unpacking zerobin
Downloading zerobin-0.3.tar.gz (207Kb): 207Kb downloaded
Running setup.py egg_info for package zerobin
warning: no files found matching '*.tx'
warning: no files found matching '*.jpg' under directory 'zerobin'
warning: no files found matching '*.gif' under directory 'zerobin'
Downloading/unpacking cherrypy (from zerobin)
Downloading CherryPy-3.2.4.tar.gz (424Kb): 424Kb downloaded
Running setup.py egg_info for package cherrypy
Downloading/unpacking bottle (from zerobin)
Downloading bottle-0.11.6.tar.gz (60Kb): 60Kb downloaded
Running setup.py egg_info for package bottle
Downloading/unpacking clize (from zerobin)
Downloading clize-2.2.tar.gz
Running setup.py egg_info for package clize
Downloading/unpacking privilege (from zerobin)
Downloading privilege-1.1.tar.gz
Running setup.py egg_info for package privilege
Installing collected packages: bottle, cherrypy, clize, privilege, zerobin
Running setup.py install for bottle
changing mode of build/scripts-2.6/bottle.py from 644 to 755
changing mode of /usr/local/bin/bottle.py to 755
Running setup.py install for cherrypy
changing mode of build/scripts-2.6/cherryd from 644 to 755
changing mode of /usr/local/bin/cherryd to 755
Running setup.py install for clize
Running setup.py install for privilege
Running setup.py install for zerobin
warning: no files found matching '*.tx'
warning: no files found matching '*.jpg' under directory 'zerobin'
warning: no files found matching '*.gif' under directory 'zerobin'
Installing zerobin script to /usr/local/bin
Successfully installed bottle cherrypy clize privilege zerobin
Cleaning up...
Run:
~/install/install036-zerobin$ zerobin
Traceback (most recent call last):
File "/usr/local/bin/zerobin", line 9, in <module>
load_entry_point('zerobin==0.3', 'console_scripts', 'zerobin')()
File "/usr/lib/python2.6/dist-packages/pkg_resources.py", line 305, in load_entry_point
return get_distribution(dist).load_entry_point(group, name)
File "/usr/lib/python2.6/dist-packages/pkg_resources.py", line 2244, in load_entry_point
return ep.load()
File "/usr/lib/python2.6/dist-packages/pkg_resources.py", line 1954, in load
entry = __import__(self.module_name, globals(),globals(), ['__name__'])
File "/usr/local/lib/python2.6/dist-packages/zerobin/routes.py", line 23, in <module>
import clize
File "/usr/local/lib/python2.6/dist-packages/clize.py", line 27, in <module>
from collections import namedtuple, OrderedDict
ImportError: cannot import name OrderedDict
Boom...
The problem is on the Clize lib: https://github.com/epsy/clize/blob/master/clize.py. The package is not compatible with Python 2.6: "OrderedDict is a new class added to Python 2.7, so it is missing in your case."
Add to had the following patch:
try:
from collections import OrderedDict
except ImportError:
# python 2.6 or earlier, use backport
from ordereddict import OrderedDict
Hello !
It is not a bug, as zerobin aims to be compatible with Python 2.7 only. See "classifiers" in https://github.com/sametmax/0bin/blob/master/setup.py.
However, we may want to make this more explicit by adding it to the README.
What's more, you probably want to make a pull request to clize with your patch, as they claim to be compatible with Python 2.6.
Cheers
In the online documentation: https://0bin.readthedocs.org/en/latest/fr/easy_install.html
30 seconds setup (for anybody)
Make sure you have Python 2.6 or 2.7 (python –version)
Installation en 30 secondes (pour tous)
Assurez-vous d’avoir Python 2.6 ou 2.7 (python –version)
Just remove the Python 2.6 ;)
Thk for the project !
I apologize for this error. I'll fix that.
No problem :)
I just propose a pull request to the Clize lib: epsy/clize#5
Thanks, this kind of help is much needed.
Le mer. 02 oct. 2013 10:47:01 CEST, Nicolas Hennion a écrit :
No problem :)
I just propose a pull request to the Clize lib: epsy/clize#5
epsy/clize#5—
Reply to this email directly or view it on GitHub
#54 (comment).