Closed Witiko closed 2 years ago
A bit short on time now, and I don’t master github actions well. I should be able to look at this within next month.
The fatal error seems related to the conversion from ESP to PDF, which is not even done by lyluatex, correct? It should be done by Hagen's conversion script when we feed an EPS image to the \pdfximage
primitive of pdfTeX.
I really don’t understand what’s wrong with this. I’ve tried to compile the example within a local texlive/texlive
controller, and it runs like a charm. @Witiko if you know github actions well, would you have a mean to get a remote shell on it, in order to debug more easily ?
@jperon I am not sure that is possible, although I am far from an expert.
I could get my hands on it thanks to https://gist.github.com/lava/62a6697abcaf6e5709939ae29e7bd4be.
The problem originates from the lilypond
command (launched by lyluatex
), which returns:
warning: g_spawn_sync failed (0): gs: Failed to close file descriptor for child process (Operation not permitted)
At first glance, it seems the problem comes from restrictions in the containers spawned by Github. @Witiko Would you mind trying to create a MWE using only lilypond
(without LuaLaTeX), to see wether the issue arises ? If so, this bug would have to be signaled upstream.
@jperon Are you certain that the issue is with lilypond? The output seems to suggest that the issue might be with the gs
command that we also execute in bbox_parse()
and in Score:optimize_pdf()
.
In the MWE, optimize-pdf
is not set. In any case, I did get this error by manually launching lilypond tmp-ly/TMPDOC.ly…
.
Thanks, I will see if I can get to try this sometime this week.
@jperon I added complilation with Lilypond to witiko/lyluatex-github-actions-example@03bdbf3
. As you correctly predicted in https://github.com/jperon/lyluatex/issues/295#issuecomment-1297463345, compilation with Lilypond is also failing on GitHub Actions. Therefore, this seems to be an upstream issue.
Before reporting the issue upstream, I would remove the Lyluatex code and try if the issue persists without the texlive/texlive:latest
Docker image, so that our MWE is truly minimal.
Before reporting the issue upstream, I would remove the Lyluatex code and try if the issue persists without the
texlive/texlive:latest
Docker image, so that our MWE is truly minimal.
Good point; if it works with default Github actions, I think it would still be worth reporting upstream, but narrowing the subject to "LilyPond fails to compile documents in GitHub Actions within default texlive image", mentionning especially those lines:
warning: g_spawn_sync failed (0): gs: Failed to close file descriptor for child process (Operation not permitted)
fatal error: cannot rename `document-tmp-7187241.502287.pdf' to `document.pdf'
At the Lilypond GitLab repository, I was told to go to the lilypond-user mailing list, which I did.
At witiko/lyluatex-github-actions-example, I created a simple MWE that shows Lyluatex failing in GitHub Actions:
I have been using GitHub Actions to typeset LaTeX documents for several years now and I have never encountered an error like this. Do you have any idea what the issue could be? I struggle to reproduce the issue outside of GitHub Actions.