Open stenlytw opened 5 years ago
I have no idea. pyppdf module imports asyncio. So may be it's bad to import it inside fuction (but that's just a guess). Few ideas to try:
import pyppdf
outside of the fuction?pyppdf.main
(that is async fuction) without asyncio instead of pyppdf.save_pdf
- the only difference is enhancing dict arguments and asyncio.get_event_loop().run_until_complete(...
.Hi,
Yes, I can import pyppdf
outside of the function. Anyway, I found a similar issue in https://stackoverflow.com/q/53679905/3387187, but I still cannot make it work.
Have you tried the solution? Both main
and save_pdf
functions can accept arguments for launch (they should be placed in the launch
dictionary field).
I still don't know if using main
instead of save_pdf
solves this issue. Reopening for now.
Hi,
Is there any way to incorporate this module into Flask Application? I tried incorporating into Flask by creating a function:
and call
render_template
as the first parameter, but got this error: