vladholubiev / serverless-libreoffice

Run LibreOffice in AWS Lambda to create PDFs & convert documents
https://vladholubiev.com/serverless-libreoffice
513 stars 75 forks source link

Fontconfig error: Cannot load default config file #31

Closed sin-tanaka closed 4 years ago

sin-tanaka commented 4 years ago

Thank you, this is great repo:)

So, I am running with lambda runtime of python 3.8.0 but I got the following error.

Fontconfig error: Cannot load default config file

Is there any solution?

rallis commented 4 years ago

I was getting same error, but managed to get proper output by making the call twice(!!) I now see in the logs twice this error message, but after that I see

Fontconfig error: Cannot load default config file Fontconfig error: Cannot load default config file convert /tmp/test.txt -> /tmp/test.pdf using filter : writer_pdf_Export

and checking the file I see it is properly converted. As of now I have no idea why this works the second time, but not the first one. Hope that helps.

vladholubiev commented 4 years ago

I came up with the same solution @rallis described

Currently, I have no workaround for this problem

sin-tanaka commented 4 years ago

I'll try it. Thanks for the very helpful information.