mystmd
mystmd copied to clipboard
LaTeX: `svg` conversion issue
trafficstars
Description
There is some issue with the dbus handling and I am not sure on which side this issue originates
$ myst build --all
...
🌠 Converting 3 images with extensions .svg to supported formats .pdf, .png, .jpg, .jpeg
terminate called after throwing an instance of 'Gio::DBus::Error'
terminate called after throwing an instance of 'Gio::DBus::Error'
Successfully converted /.../_build/exports/test_pdf_tex/files/spread-bc04d88ca240f3b280d2ecabed2048aa.svg -> files/spread-bc04d88ca240f3b280d2ecabed2048aa.pdf
⛔️ _build/exports/test_pdf_tex/files/bandstructure-86e773631a86cd9845215fee30911084.svg Could not convert from SVG to PDF - Error: Command failed: inkscape _build/exports/test_pdf_tex/files/bandstructure-86e773631a86cd9845215fee30911084.svg --export-area-drawing --export-type=pdf --export-filename=_build/exports/test_pdf_tex/files/bandstructure-86e773631a86cd9845215fee30911084.pdf
Workaround
Adding DBUS_SESSION_BUS_ADDRESS="" seems to work around this issue
$ DBUS_SESSION_BUS_ADDRESS="" myst build --all
Proposed solution
Probably we need more debugging
These logs/conversions are coming from inkscape, but if there are more environment variables, etc. that we should be setting to ensure that things work that is certainly on MyST. I haven't come across this particular error before, so we might need help reproducing.
Has anyone previously looked at whether PDFKit a viable alternative to inkscape?