Not working with uvloop
sevaho opened this issue · comments
#! /usr/bin/python
import asyncio
import aiohttp
import uvloop
from pydf import AsyncPydf
html = "<html>hello</html>"
uvloop.install() # toggle this line on/off
async def generate_async():
apydf = AsyncPydf()
await apydf.generate_pdf(html)
asyncio.run(generate_async())
Error:
untimeError: error running wkhtmltopdf, command: ['/home/sevaho/.local/share/virtualenvs/test-hTe5GLvs/lib/python3.8/sit
e-packages/pydf/bin/wkhtmltopdf', '--cache-dir', '/tmp/pydf_cache', '-', '-']
response: "Loading pages (1/6)
QPainter::begin(): Returned false============================] 100%
Error: Unable to write to destination
Exit with code 1, due to unknown error."