PDF Generation hangs using PDFKit and wkhtmotopdf

故事扮演 提交于 2019-12-20 07:35:04

问题


I'm on OSX Lion using wkhtmtopdf that came with homebrew (0.9.9) and all of the sudden I cannot generate PDFs anymore. When I tack .pdf on the end of a URL, the wkhtmltopdf process fires up, but the process never completes. I suspect it's an issue with wkhtmltopdf because the process is not completing when I run it via the cli either. When I issue the following command, I get a test.pdf file, but the process never finishes, even though it says "done".

Is there something I can do to force the process to complete?

curl google.com | wkhtmltopdf - test.pdf

  % Total    % Received % Xferd  Average Speed   Time    Time     Time  Current
                                 Dload  Upload   Total   Spent    Left  Speed
100   219  100   219    0     0   1685      0 --:--:-- --:--:-- --:--:--  5475
Loading page (1/2)
Printing pages (2/2)                                               
Done

回答1:


Turns out it had nothing to do with the cli and it was actually due to Jammit running in development. Disabling Jammit fixes the PDFkit hanging issue.



来源:https://stackoverflow.com/questions/10045327/pdf-generation-hangs-using-pdfkit-and-wkhtmotopdf

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!