Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]
Groups > comp.lang.python > #80024
| X-Received | by 10.236.189.225 with SMTP id c61mr12379747yhn.34.1414773981501; Fri, 31 Oct 2014 09:46:21 -0700 (PDT) |
|---|---|
| X-Received | by 10.140.94.212 with SMTP id g78mr424561qge.0.1414773981441; Fri, 31 Oct 2014 09:46:21 -0700 (PDT) |
| Path | csiph.com!v102.xanadu-bbs.net!xanadu-bbs.net!usenet.blueworldhosting.com!feeder01.blueworldhosting.com!peer02.iad.highwinds-media.com!news.highwinds-media.com!feed-me.highwinds-media.com!border1.nntp.dca1.giganews.com!nntp.giganews.com!u7no1471450qaz.1!news-out.google.com!u5ni17qab.1!nntp.google.com!u7no1471449qaz.1!postnews.google.com!glegroupsg2000goo.googlegroups.com!not-for-mail |
| Newsgroups | comp.lang.python |
| Date | Fri, 31 Oct 2014 09:46:21 -0700 (PDT) |
| Complaints-To | groups-abuse@google.com |
| Injection-Info | glegroupsg2000goo.googlegroups.com; posting-host=170.63.67.1; posting-account=FD9bUQkAAAALXoGMw2NOrxFh83g2JH-L |
| NNTP-Posting-Host | 170.63.67.1 |
| User-Agent | G2/1.0 |
| MIME-Version | 1.0 |
| Message-ID | <ff33a03e-8b6a-427d-b4ea-c267a768cb15@googlegroups.com> (permalink) |
| Subject | Implementing pdfkit and wkhtmltopdf on windows fails |
| From | robert brook <software.by.python@gmail.com> |
| Injection-Date | Fri, 31 Oct 2014 16:46:21 +0000 |
| Content-Type | text/plain; charset=ISO-8859-1 |
| Lines | 29 |
| X-Received-Bytes | 2425 |
| X-Received-Body-CRC | 389865748 |
| Xref | csiph.com comp.lang.python:80024 |
Show key headers only | View raw
I am able to install both of these packages on my mac at home and it works well.
I am trying to install on windows 7 at work and it fails. PDFKit is trying to find the wkh package and it cannot. I have entered the full path to the exe for the environment variables and the error below is spit out.
If I explicitly cd into the directory that has the executable the script works fine
>>> import os
>>> path='C:\\wkhtmltopdf\\bin\\'
>>> os.chdir(path)
>>> pdfkit.from_string('Hello!', 'out.pdf')
Loading pages (1/6) #this works after cd into the exe directory
Where can I specify the path to the executable?
*************
Traceback (most recent call last):
File "<stdin>", line 1, in <module>
File "C:\Applications\python_33_32_bit\lib\site-packages\pdfkit-0.4.1-py3.3.eg
g\pdfkit\api.py", line 66, in from_string
File "C:\Applications\python_33_32_bit\lib\site-packages\pdfkit-0.4.1-py3.3.eg
g\pdfkit\pdfkit.py", line 39, in __init__
File "C:\Applications\python_33_32_bit\lib\site-packages\pdfkit-0.4.1-py3.3.eg
g\pdfkit\configuration.py", line 27, in __init__
OSError: No wkhtmltopdf executable found: "b''"
If this file exists please check that this process can read it. Otherwise please
install wkhtmltopdf - https://github.com/JazzCore/python-pdfkit/wiki/Installing
-wkhtmltopdf
**********************
Back to comp.lang.python | Previous | Next — Next in thread | Find similar | Unroll thread
Implementing pdfkit and wkhtmltopdf on windows fails robert brook <software.by.python@gmail.com> - 2014-10-31 09:46 -0700
Re: Implementing pdfkit and wkhtmltopdf on windows fails Dave Angel <davea@davea.name> - 2014-10-31 13:02 -0400
Re: Implementing pdfkit and wkhtmltopdf on windows fails robert brook <software.by.python@gmail.com> - 2014-10-31 10:25 -0700
Re: Implementing pdfkit and wkhtmltopdf on windows fails Peter Otten <__peter__@web.de> - 2014-10-31 18:45 +0100
csiph-web