Subject: [xml2rfc] epub broken

From: Marius Scurtescu <[email-masked]>
Date: Thu, 25 Jan 2018 11:17:46 -0800

Trying to generate epub I get the following error:
Traceback (most recent call last):
  File "/usr/bin/ebook-convert", line 19, in <module>
    sys.exit(main())
  File "/usr/lib/calibre/calibre/ebooks/conversion/cli.py", line 323, in
main
    plumber.run()
  File "/usr/lib/calibre/calibre/ebooks/conversion/plumber.py", line 1021,
in run
    from calibre.ebooks.oeb.transforms.flatcss import CSSFlattener
  File "/usr/lib/calibre/calibre/ebooks/oeb/transforms/flatcss.py", line
17, in <module>
    from calibre.ebooks.oeb.stylizer import Stylizer
  File "/usr/lib/calibre/calibre/ebooks/oeb/stylizer.py", line 23, in
<module>
    from lxml.cssselect import css_to_xpath, ExpressionError,
SelectorSyntaxError
ImportError: cannot import name css_to_xpath

The experimental version leads to the exact same error.

This is the XML that I wanted to convert:
https://tools.ietf.org/id/draft-ietf-secevent-token-04.xml

Suggestions?

Thanks,
Marius

---

From: Henrik Levkowetz <[email-masked]>
Date: Thu, 25 Jan 2018 22:26:34 +0100

Hi Marius,

> https://tools.ietf.org/id/draft-ietf-secevent-token-04.xml

It seems that the interface to cssselect within lxml has changed with
lxml 3.0, and the calibre ebook-convert uses the old inteface.  I've
now told the ebook-convert wrapper to use a local python environment
where I've installed a compatible version of lxml, and things work
when I test the web service and from the command line here.  Could you
please check to see that this now work for you?

Best regards,

	Henrik

---

From: Marius Scurtescu <[email-masked]>
Date: Thu, 25 Jan 2018 13:48:01 -0800

Yes, it worked now. Thanks a lot Henrik!

Marius