Koha and xhtml2pdf
Hie. We have some problems with xhtml2pdf on Ubuntu Xenial. This soft is used by misc/cronjobs/printoverdues.sh. First it is strange that the package containing this soft "python-pisa" is not in koha-deps. I see there is "html2pdf" but there is no CSS option. In jessie we have to use the jessie-backports repo and install several packages : python-pisa python3-reportlab python-html5lib python-pypdf python-imaging python-renderpm python-reportlab python-reportlab-accel On ubuntu Xenial, we install those same packages but we have a bug in python call. We found it can be corrected by installing xhtml2pdf from its GIT repo. We would prefere to avoid this. Any help is welcome. Best regards, -- Fridolin SOMERS Biblibre - Pôles support et système fridolin.somers@biblibre.com
Hi Frido, The script is telling you to install it using easy_install. If you want an alternative, take a look at PDF::FromHTML, it's what we use to generate discharges. Cheers, Jonathan On Thu, 20 Apr 2017 at 07:31 Fridolin SOMERS <fridolin.somers@biblibre.com> wrote:
Hie.
We have some problems with xhtml2pdf on Ubuntu Xenial.
This soft is used by misc/cronjobs/printoverdues.sh. First it is strange that the package containing this soft "python-pisa" is not in koha-deps. I see there is "html2pdf" but there is no CSS option.
In jessie we have to use the jessie-backports repo and install several packages : python-pisa python3-reportlab python-html5lib python-pypdf python-imaging python-renderpm python-reportlab python-reportlab-accel
On ubuntu Xenial, we install those same packages but we have a bug in python call. We found it can be corrected by installing xhtml2pdf from its GIT repo. We would prefere to avoid this.
Any help is welcome.
Best regards,
-- Fridolin SOMERS Biblibre - Pôles support et système fridolin.somers@biblibre.com _______________________________________________ Koha-devel mailing list Koha-devel@lists.koha-community.org http://lists.koha-community.org/cgi-bin/mailman/listinfo/koha-devel website : http://www.koha-community.org/ git : http://git.koha-community.org/ bugs : http://bugs.koha-community.org/
This may not be relevant to Ubuntu, but I was able to get a working xhtml2pdf on Debian Jessie using this: apt-get install python-pip python-dev pip install xhtml2pdf Before figuring this out, I tried using 'easy_install pisa', but xhtml2pdf complained about missing dependencies and I was too lazy to figure out how to install them. One thing I discovered during this head-scratching phase was that easy_install has been deprecated, and pip is used nowadays, which led me to the above solution.
Okiii, thanks a lot Le 21/04/2017 à 00:57, Mark Alexander a écrit :
This may not be relevant to Ubuntu, but I was able to get a working xhtml2pdf on Debian Jessie using this:
apt-get install python-pip python-dev pip install xhtml2pdf
Before figuring this out, I tried using 'easy_install pisa', but xhtml2pdf complained about missing dependencies and I was too lazy to figure out how to install them. One thing I discovered during this head-scratching phase was that easy_install has been deprecated, and pip is used nowadays, which led me to the above solution.
-- Fridolin SOMERS Biblibre - Pôles support et système fridolin.somers@biblibre.com
Yeah, no one uses easy_install anymore. It's all about pip. However, the community likes to have everything packaged, and using pip is like using cpan... so this seems like an issue to me. Does Koha have anyone of notifying that there's a dependency missing if it's not installed in this case? David Cook Systems Librarian Prosentient Systems 72/330 Wattle St Ultimo, NSW 2007 Australia Office: 02 9212 0899 Direct: 02 8005 0595
-----Original Message----- From: koha-devel-bounces@lists.koha-community.org [mailto:koha-devel- bounces@lists.koha-community.org] On Behalf Of Mark Alexander Sent: Friday, 21 April 2017 8:57 AM To: Fridolin SOMERS <fridolin.somers@biblibre.com> Cc: koha-devel <koha-devel@lists.koha-community.org> Subject: Re: [Koha-devel] Koha and xhtml2pdf
This may not be relevant to Ubuntu, but I was able to get a working xhtml2pdf on Debian Jessie using this:
apt-get install python-pip python-dev pip install xhtml2pdf
Before figuring this out, I tried using 'easy_install pisa', but xhtml2pdf complained about missing dependencies and I was too lazy to figure out how to install them. One thing I discovered during this head-scratching phase was that easy_install has been deprecated, and pip is used nowadays, which led me to the above solution. _______________________________________________ Koha-devel mailing list Koha-devel@lists.koha-community.org http://lists.koha-community.org/cgi-bin/mailman/listinfo/koha-devel website : http://www.koha-community.org/ git : http://git.koha-community.org/ bugs : http://bugs.koha-community.org/
Hie devels, Finally we solved by downgrading the lib Pillow to 2.7 using Python PIP. Note that is this in Ubuntu Xenial. Le 24/04/2017 à 10:08, David Cook a écrit :
Yeah, no one uses easy_install anymore. It's all about pip.
However, the community likes to have everything packaged, and using pip is like using cpan... so this seems like an issue to me. Does Koha have anyone of notifying that there's a dependency missing if it's not installed in this case?
David Cook Systems Librarian Prosentient Systems 72/330 Wattle St Ultimo, NSW 2007 Australia
Office: 02 9212 0899 Direct: 02 8005 0595
-----Original Message----- From: koha-devel-bounces@lists.koha-community.org [mailto:koha-devel- bounces@lists.koha-community.org] On Behalf Of Mark Alexander Sent: Friday, 21 April 2017 8:57 AM To: Fridolin SOMERS <fridolin.somers@biblibre.com> Cc: koha-devel <koha-devel@lists.koha-community.org> Subject: Re: [Koha-devel] Koha and xhtml2pdf
This may not be relevant to Ubuntu, but I was able to get a working xhtml2pdf on Debian Jessie using this:
apt-get install python-pip python-dev pip install xhtml2pdf
Before figuring this out, I tried using 'easy_install pisa', but xhtml2pdf complained about missing dependencies and I was too lazy to figure out how to install them. One thing I discovered during this head-scratching phase was that easy_install has been deprecated, and pip is used nowadays, which led me to the above solution. _______________________________________________ Koha-devel mailing list Koha-devel@lists.koha-community.org http://lists.koha-community.org/cgi-bin/mailman/listinfo/koha-devel website : http://www.koha-community.org/ git : http://git.koha-community.org/ bugs : http://bugs.koha-community.org/
-- Fridolin SOMERS Biblibre - Pôles support et système fridolin.somers@biblibre.com
participants (4)
-
David Cook -
Fridolin SOMERS -
Jonathan Druart -
Mark Alexander