'Static files are not loaded generating pdf from html when application run in ASGI layer

I use Weasyprint to generate pdf from HTML. When run the application in ASGI static files are not loaded in pdf, but if I run the application in WSGI then the static file loads correctly. How can I solve this issue?



Sources

This article follows the attribution requirements of Stack Overflow and is licensed under CC BY-SA 3.0.

Source: Stack Overflow

Solution Source