error on setup

382 views
Skip to first unread message

jona

unread,
Dec 19, 2010, 3:28:52 PM12/19/10
to PyF Framework Users
Everything seems to get smooth until the setup.

What I get is :

(pyfenv)jona@jona-desktop:~/Softwares/pyf/pyfenv$ pyfservices-setup
pyfservices.ini
Traceback (most recent call last):
File "/home/jona/Softwares/pyf/pyfenv/bin/pyfservices-setup", line
5, in <module>
from pkg_resources import load_entry_point
File "/home/jona/Softwares/pyf/pyfenv/lib/python2.6/site-packages/
setuptools-0.6c11-py2.6.egg/pkg_resources.py", line 2603, in <module>
File "/home/jona/Softwares/pyf/pyfenv/lib/python2.6/site-packages/
setuptools-0.6c11-py2.6.egg/pkg_resources.py", line 666, in require
File "/home/jona/Softwares/pyf/pyfenv/lib/python2.6/site-packages/
setuptools-0.6c11-py2.6.egg/pkg_resources.py", line 565, in resolve
pkg_resources.DistributionNotFound: lxml>=2.2

I there something I was missing ?

Thanks,

Jona

Mathieu Bridon

unread,
Dec 19, 2010, 3:39:42 PM12/19/10
to pyf-...@googlegroups.com
Hi Jona,

On Sun, 2010-12-19 at 12:28 -0800, jona wrote:
> Everything seems to get smooth until the setup.
>
> What I get is :

[... snip ...]


> pkg_resources.DistributionNotFound: lxml>=2.2
>
> I there something I was missing ?

Yes, as the message says, you probably didn't install lxml, which is
required by PyF.Services.

Can you find it in your virtualenv?

If not, you can install it with the following command (with the
virtualenv activated):
$ easy_install "lxml>=2.2"

It would be useful to know why you don't have it. Do you still have the
logs from running the bootstrap script?


--
Mathieu


jona

unread,
Dec 19, 2010, 3:51:39 PM12/19/10
to PyF Framework Users
Thanks for the fast feedback !

In fact there was a problem here :

Installed /home/jona/Softwares/pyf/pyfenv/lib/python2.6/site-packages/
reportlab-2.5-py2.6-linux-x86_64.egg
Searching for lxml
Reading http://pypi.python.org/simple/lxml/
Reading http://codespeak.net/lxml
Best match: lxml 2.3beta1
Downloading http://pypi.python.org/packages/source/l/lxml/lxml-2.3beta1.tar.gz
Processing lxml-2.3beta1.tar.gz
Running lxml-2.3beta1/setup.py -q bdist_egg --dist-dir /tmp/
easy_install-F5PfIY/lxml-2.3beta1/egg-dist-tmp-zUf8zf
Building lxml version 2.3.beta1.
NOTE: Trying to build without Cython, pre-generated 'src/lxml/
lxml.etree.c' needs to be available.
ERROR: /bin/sh: xslt-config: not found

** make sure the development packages of libxml2 and libxslt are
installed **

Using build configuration of libxslt
In file included from src/lxml/lxml.etree.c:203:
src/lxml/etree_defs.h:9: fatal error: libxml/xmlversion.h: No such
file or directory
compilation terminated.
error: Setup script exited with error: command 'gcc' failed with exit
status 1
Running command....
pyfenv/bin/easy_install pyf.components.consumers.xhtmlpdfwriter
Searching for pyf.components.consumers.xhtmlpdfwriter
Reading http://pypi.python.org/simple/pyf.components.consumers.xhtmlpdfwriter/
Reading http://pyfproject.org
Best match: pyf.components.consumers.xhtmlpdfwriter 0.2
Downloading
http://pypi.python.org/packages/2.6/p/pyf.components.consumers.xhtmlpdfwriter/pyf.components.consumers.xhtmlpdfwriter-0.2-py2.6.egg#md5=07051af5cd41471ddb2532ec9c537c1f
Processing pyf.components.consumers.xhtmlpdfwriter-0.2-py2.6.egg
Moving pyf.components.consumers.xhtmlpdfwriter-0.2-py2.6.egg to /home/
jona/Softwares/pyf/pyfenv/lib/python2.6/site-packages
Adding pyf.components.consumers.xhtmlpdfwriter 0.2 to easy-install.pth
file
...

The same error shows up when I tried you command :
easy_install "lxml>=2.2"

Is the problem that libxslt-dev is not installed ?

Thanks,

Jona

jona

unread,
Dec 19, 2010, 4:05:54 PM12/19/10
to PyF Framework Users
It works !

I installed libxslt-dev, launching the bootstrap script again and then
it works, thanks !

Jona

Mathieu Bridon

unread,
Dec 19, 2010, 4:23:52 PM12/19/10
to pyf-...@googlegroups.com
On Sun, 2010-12-19 at 13:05 -0800, jona wrote:
> It works !
>
> I installed libxslt-dev,

This is indeed required to build lxml.

> launching the bootstrap script again and then
> it works, thanks !

Yeah, that's what I suspected.

Unfortunately, easy_install is not transactional. So if one of the stuff
the bootstrap script tries to install fails for some reason, it just
prints an error and goes on to install the rest, and (as happened to
you) the user can just miss the error message.

I'm glad you got it to work though.

Cheers,


--
Mathieu


Reply all
Reply to author
Forward
0 new messages