HTML -> Image (Python)
All i want to do is convert a pandas dataframe (which can be expressed as an HTML table) to an image file. I've tried 1) dataframe-image and 2) html2image which both use chrome. I've installed as many helper packages i can find to try to get chrome to work, but the final boss error is 'cannot connect to dbus/system_bus_socket: no such file or directory'. I've also tried 3) imgkit which uses wkhtmltopdf/wkhtmltoimage. When I put NIXPACKS_PKGS=wkhtmltopdf
6 Replies
Project ID:
N/A
You might find these helpful:
- File I/O Python
- Incorporating wkhtmltopdf
- Chrome / Chrome Driver paths
⚠️ experimental feature
So how opposed are you to rewriting your app in node?
fixed using method 3 and NIXPACKS_PKGS=wkhtmltopdf-bin
So all good?
All good!