Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

weasyprint failing to convert any HTML inside docker #2623

Open
SBGit-2019 opened this issue Apr 30, 2024 · 1 comment
Open

weasyprint failing to convert any HTML inside docker #2623

SBGit-2019 opened this issue Apr 30, 2024 · 1 comment
Labels
question Further information is requested

Comments

@SBGit-2019
Copy link

Using the docker setup (v0.41) HTML documents are not converted to PDF. This applies to all HTML I uploaded.
The weasyprint command hangs till timeout. Manually starting the weasyprint in the container works.

So either the document is not where the weasyprint expects it or the options to weasyprint are wrong.

Here is the log

Di.. 30. April 2024, 6:33: ============ Start processing 22.html ============
Di.. 30. April 2024, 6:33: Checking for duplicate files
Di.. 30. April 2024, 6:33: Creating new item with 1 attachment(s)
Di.. 30. April 2024, 6:33: Creating item finished in 6 ms
Di.. 30. April 2024, 6:33: Not an archive: text/html; charset="UTF-8"
Di.. 30. April 2024, 6:33: Converting file Some(22.html) (text/html; charset="UTF-8") into a PDF
Di.. 30. April 2024, 6:33: Running external command: weasyprint --optimize-size all --encoding UTF-8 - /tmp/docspell-weasyprint/docspell-weasyprint1105130546458020598/out.pdf
Di.. 30. April 2024, 6:35: Command `weasyprint --optimize-size all --encoding UTF-8 - /tmp/docspell-weasyprint/docspell-weasyprint1105130546458020598/out.pdf` did not finish in 120000 ms!
Di.. 30. April 2024, 6:35: Closing process: `weasyprint --optimize-size all --encoding UTF-8 - /tmp/docspell-weasyprint/docspell-weasyprint1105130546458020598/out.pdf`
Di.. 30. April 2024, 6:35: PDF conversion failed: Command `weasyprint --optimize-size all --encoding UTF-8 - /tmp/docspell-weasyprint/docspell-weasyprint1105130546458020598/out.pdf` timed out (120000 ms). Go without PDF file

Can the weasyprint command be configured somewhere?

@eikek
Copy link
Owner

eikek commented May 10, 2024

Yes, all the commands can be configured. If you look at the default config (https://docspell.org/docs/configure/defaults/#joex) you can find the section configuring weasyprint.

@eikek eikek added the question Further information is requested label May 10, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
question Further information is requested
Projects
None yet
Development

No branches or pull requests

2 participants