`guix import texlive PKG` fails with signal 11, no output

  • Done
  • quality assurance status badge
Details
4 participants
  • Hugo Nobrega
  • Jack Hill
  • Ludovic Courtès
  • Tobias Geerinckx-Rice
Owner
unassigned
Submitted by
Hugo Nobrega
Severity
normal
Merged with
H
H
Hugo Nobrega wrote on 22 May 2022 22:26
(address . bug-guix@gnu.org)
87o7zpiaa8.fsf@gmail.com
Hello,

The guix 'texlive' package importer is not working with any package, as
far as I can tell. It does *some* legwork, managing to figure out the
correct URI of the package, but then errors out with signal 11.

Having had a look at previous bug reports, it seems this "signal 11"
thing is not new (e.g., bug#28303), but in any case I am not seeing any
output after the error (unlike what seemed to be happening in bug#28303)

Example:

hugo@hp-guix ~$ guix import texlive cite
command "svn" "export" "--non-interactive" "--trust-server-cert" "-r"
"59745"
"svn://www.tug.org/texlive/tags/texlive-2021.3/Master/texmf-dist/doc/latex/cite/"
"/tmp/guix-directory.09UnsN/doc/latex/cite/" failed with signal 11 guix
import: error: failed to import package 'cite'

Best regards,
Hugo
L
L
Ludovic Courtès wrote on 24 May 2022 15:34
control message for bug #55587
(address . control@debbugs.gnu.org)
87tu9fkqba.fsf@gnu.org
merge 55587 55596
quit
L
L
Ludovic Courtès wrote on 25 May 2022 12:36
Re: bug#55596: Guix/Guile segfaults on `guix import texlive`
(name . Hugo Nobrega)(address . hugonobrega@ic.ufrj.br)
878rqpj3vz.fsf@gnu.org
Hello,

Hugo Nobrega <hugonobrega@ic.ufrj.br> skribis:

Toggle quote (7 lines)
> hugo@hp-guix ~$ guix import texlive cite
> command "svn" "export" "--non-interactive" "--trust-server-cert" "-r"
> "59745"
> "svn://www.tug.org/texlive/tags/texlive-2021.3/Master/texmf-dist/doc/latex/cite/"
> "/tmp/guix-directory.09UnsN/doc/latex/cite/" failed with signal 11 guix
> import: error: failed to import package 'cite'

Jack Hill <jackhill@jackhill.us> skribis:

Toggle quote (12 lines)
> With Guix commit 4ba4cb1d49d70a00f7236f60bd92e5eccef573dd on Linux
> x86-64, I have the following problem trying to import a texlive
> package:
>
> """
> $ guix import texlive qrcode
> command "svn" "export" "--non-interactive" "--trust-server-cert" "-r" "59745" "svn://www.tug.org/texlive/tags/texlive-2021.3/Master/texmf-dist/doc/latex/qrcode/" "/tmp/guix-directory.6aY7Gk/doc/latex/qrcode/" failed with signal 11
> guix import: error: failed to import package 'qrcode'
> """
>
> It seems something is unwell with our subversion package?

Works for me on x86_64-linux!

Toggle snippet (63 lines)
$ guix describe
Generation 215 May 22 2022 23:16:03 (current)
guix 81f7bb1
repository URL: https://git.savannah.gnu.org/git/guix.git
branch: master
commit: 81f7bb1691dc9dc69fc6e584ad8c6e36e495c103
$ guix shell subversion -- guix import texlive qrcode
A /tmp/guix-directory.rXo6NK/doc/latex/qrcode
A /tmp/guix-directory.rXo6NK/doc/latex/qrcode/README
A /tmp/guix-directory.rXo6NK/doc/latex/qrcode/qrcode.pdf
Exported revision 59745.
A /tmp/guix-directory.rXo6NK/source/latex/qrcode
A /tmp/guix-directory.rXo6NK/source/latex/qrcode/qrcode.dtx
A /tmp/guix-directory.rXo6NK/source/latex/qrcode/qrcode.ins
Exported revision 59745.
A /tmp/guix-directory.rXo6NK/tex/latex/qrcode
A /tmp/guix-directory.rXo6NK/tex/latex/qrcode/qrcode.sty
Exported revision 59745.
(package
(inherit
(simple-texlive-package
"texlive-qrcode"
(list "doc/latex/qrcode/" "source/latex/qrcode/" "tex/latex/qrcode/")
(base32 "197v18lsvb90i07gxvc6mrmn1z63q8v0wvcnbk8dnn3hhabpn16y")))
(home-page "https://ctan.org/macros/latex/contrib/qrcode")
(synopsis "Generate QR codes in LaTeX")
(description
"The package generates QR (Quick Response) codes in LaTeX, without the need for
PSTricks or any other graphical package.")
(license lppl1.3+))
$ guix shell subversion -- guix import texlive cite
A /tmp/guix-directory.GpxhKw/doc/latex/cite
A /tmp/guix-directory.GpxhKw/doc/latex/cite/README
A /tmp/guix-directory.GpxhKw/doc/latex/cite/chapterbib.ltx
A /tmp/guix-directory.GpxhKw/doc/latex/cite/chapterbib.pdf
A /tmp/guix-directory.GpxhKw/doc/latex/cite/cite.ltx
A /tmp/guix-directory.GpxhKw/doc/latex/cite/cite.pdf
Exported revision 59745.
A /tmp/guix-directory.GpxhKw/tex/latex/cite
A /tmp/guix-directory.GpxhKw/tex/latex/cite/chapterbib.sty
A /tmp/guix-directory.GpxhKw/tex/latex/cite/cite.sty
A /tmp/guix-directory.GpxhKw/tex/latex/cite/drftcite.sty
A /tmp/guix-directory.GpxhKw/tex/latex/cite/overcite.sty
Exported revision 59745.
(package
(inherit
(simple-texlive-package
"texlive-cite"
(list "doc/latex/cite/" "tex/latex/cite/")
(base32 "0b1amznayxj80dmqbzcysmj7q8aksbyz98k6djsqi0mhwp1cd0fd")
#:trivial?
#t))
(home-page "https://ctan.org/macros/latex/contrib/cite")
(synopsis "Improved citation handling in LaTeX")
(description
"The package supports compressed, sorted lists of numerical citations, and also
deals with various punctuation and other issues of representation, including
comprehensive management of break points. The package is compatible with both
hyperref and backref. The package is (unsurprisingly) part of the cite bundle
of the author's citation-related packages.")
(license (error unknown-license "other-free")))

Jack, Hugo: What does “type -P svn” say?

Does the bug occur within ‘guix shell subversion’ as shown above?

TIA,
Ludo’.
H
(name . Ludovic Courtès)(address . ludo@gnu.org)
878rqpxhxy.fsf@gmail.com
Ludovic Courtès <ludo@gnu.org> writes:

Toggle quote (4 lines)
> Jack, Hugo: What does “type -P svn” say?
>
> Does the bug occur within ‘guix shell subversion’ as shown above?

Well, I feel kind of silly now, after actually installing subversion the
command works as expected :)

But I suppose the silent failure is still something that could/should be
improved.

Thanks,
Hugo
J
J
Jack Hill wrote on 26 May 2022 15:36
Re: bug#55587: bug#55596: Guix/Guile segfaults on `guix import texlive`
(name . Hugo)(address . hugonobrega@ic.ufrj.br)
alpine.DEB.2.21.2205260933340.11587@marsh.hcoop.net
On Wed, 25 May 2022, Hugo wrote:

Toggle quote (9 lines)
> Ludovic Courtès <ludo@gnu.org> writes:
>
>> Jack, Hugo: What does “type -P svn” say?
>>
>> Does the bug occur within ‘guix shell subversion’ as shown above?
>
> Well, I feel kind of silly now, after actually installing subversion the
> command works as expected :)

Same for me, and I feel equally silly :)

Toggle quote (3 lines)
> But I suppose the silent failure is still something that could/should be
> improved.

+1 for this. Maybe some day we'll have have guile-svn, but until then an
error message would be fine.

Best,
Jack
L
L
Ludovic Courtès wrote on 28 May 2022 19:19
Re: bug#55596: Guix/Guile segfaults on `guix import texlive`
(name . Jack Hill)(address . jackhill@jackhill.us)
875ylpbmna.fsf_-_@gnu.org
Hi,

Jack Hill <jackhill@jackhill.us> skribis:

Toggle quote (13 lines)
> On Wed, 25 May 2022, Hugo wrote:
>
>> Ludovic Courtès <ludo@gnu.org> writes:
>>
>>> Jack, Hugo: What does “type -P svn” say?
>>>
>>> Does the bug occur within ‘guix shell subversion’ as shown above?
>>
>> Well, I feel kind of silly now, after actually installing subversion the
>> command works as expected :)
>
> Same for me, and I feel equally silly :)

You mentioned an error report from Guix:

command "svn" "export" "--non-interactive" "--trust-server-cert" "-r" "59745" "svn://www.tug.org/texlive/tags/texlive-2021.3/Master/texmf-dist/doc/latex/cite/" "/tmp/guix-directory.09UnsN/doc/latex/cite/" failed with signal 11

To me that means that an “svn” command was indeed found in $PATH but
that it segfaulted.

What did “type -P svn” return? Perhaps there was an “svn” command
coming from the host distro, like /usr/bin/svn?

Or am I missing something?

Thanks,
Ludo’.
T
T
Tobias Geerinckx-Rice wrote on 28 May 2022 20:51
Re: bug#55587: bug#55596: Guix/Guile segfaults on `guix import texlive`
(name . Ludovic Courtès)(address . ludo@gnu.org)
87y1ylwkm8@nckx
Hi,

I thought I'd replied to this.

I think you might be barking up the wrong tree (or, likely, that
there are multiple trees here). I could reproduce the segfault on
Guix System and encouraged Jack to file this bug.

It's not foreign-distro-related. The process actually segfaulting
is Guix, not svn, possibly due to a missing svn.

Kind regards,

T G-R
-----BEGIN PGP SIGNATURE-----

iIMEARYKACsWIQT12iAyS4c9C3o4dnINsP+IT1VteQUCYpJwnw0cbWVAdG9iaWFz
LmdyAAoJEA2w/4hPVW15Sy0A/RJB/HnevGbxPyEUgdrSymj1xmn5paN8makZV09x
obWdAP9rElqLGno8//BErXxYIsu15PqmgT4TNkpDILJgDbXhDA==
=iIfO
-----END PGP SIGNATURE-----

H
877d643alm.fsf@gmail.com
Hello,

Toggle quote (3 lines)
> It's not foreign-distro-related. The process actually segfaulting
> is Guix, not svn, possibly due to a missing svn.

Indeed, I think Tobias is on the right track here.
However, I can no longer reproduce the `signal 11` error

To answer Ludò, though,

Toggle quote (2 lines)
> What did “type -P svn” return?

Before I installed subversion: nothing. Now it shows the correct path to
svn.

Toggle quote (3 lines)
> Perhaps there was an “svn” command coming from the host distro, like
> /usr/bin/svn?

Nope, this is on Guix System.

Best wishes,
Hugo
L
L
Ludovic Courtès wrote on 15 Jun 2022 22:39
Re: bug#55596: Guix/Guile segfaults on `guix import texlive`
(name . Tobias Geerinckx-Rice)(address . me@tobias.gr)
87sfo5psp2.fsf_-_@gnu.org
Hello,

Tobias Geerinckx-Rice <me@tobias.gr> skribis:

Toggle quote (7 lines)
> I think you might be barking up the wrong tree (or, likely, that there
> are multiple trees here). I could reproduce the segfault on Guix
> System and encouraged Jack to file this bug.
>
> It's not foreign-distro-related. The process actually segfaulting is
> Guix, not svn, possibly due to a missing svn.

I don’t think so; the error message that was reported is:

command "svn" "export" "--non-interactive" "--trust-server-cert" "-r" "59745" "svn://www.tug.org/texlive/tags/texlive-2021.3/Master/texmf-dist/doc/latex/cite/" "/tmp/guix-directory.09UnsN/doc/latex/cite/" failed with signal 11

It’s a message from ‘report-invoke-error’ in (guix build utils). It’s
really svn that’s segfaulting.

Should we close and reopen if/when we have more info?

Thanks,
Ludo’.
L
L
Ludovic Courtès wrote on 5 Aug 2022 14:22
(name . Tobias Geerinckx-Rice)(address . me@tobias.gr)
87czdehobw.fsf@gnu.org
Hi,

Ludovic Courtès <ludo@gnu.org> skribis:

Toggle quote (7 lines)
> I don’t think so; the error message that was reported is:
>
> command "svn" "export" "--non-interactive" "--trust-server-cert" "-r" "59745" "svn://www.tug.org/texlive/tags/texlive-2021.3/Master/texmf-dist/doc/latex/cite/" "/tmp/guix-directory.09UnsN/doc/latex/cite/" failed with signal 11
>
> It’s a message from ‘report-invoke-error’ in (guix build utils). It’s
> really svn that’s segfaulting.

Maybe not! I can trigger it reproducibly:

Toggle snippet (14 lines)
ludo@ribbon ~/src/guix [env]$ guix describe
Generation 223 Aug 01 2022 00:30:24 (current)
guix ab59155
repository URL: https://git.savannah.gnu.org/git/guix.git
branch: master
commit: ab59155c5a38dda7efaceb47c7528578fcf0def4
ludo@ribbon ~/src/guix [env]$ rm -f core
ludo@ribbon ~/src/guix [env]$ guix import texlive abstract
command "svn" "export" "--non-interactive" "--trust-server-cert" "-r" "59745" "svn://www.tug.org/texlive/tags/texlive-2021.3/Master/texmf-dist/doc/latex/abstract/" "/tmp/guix-directory.HYEHpM/doc/latex/abstract/" failed with signal 11
guix import: error: failed to download description for package 'abstract'
ludo@ribbon ~/src/guix [env]$ file core
core: ELF 64-bit LSB core file, x86-64, version 1 (SYSV), SVR4-style, from '/gnu/store/9z95jms1r801z1kxpiq5xw594cxaw5jx-guile-wrapper/bin/guile --no-auto-c', real uid: 1000, effective uid: 1000, real gid: 998, effective gid: 998, execfn: '/home/ludo/.config/guix/current/bin/guix', platform: 'x86_64'

Actually it happens when ‘svn’ is not in $PATH, triggering a crash in
Guile as it tries to display an error in the child process:

Toggle snippet (22 lines)
$ gdb /gnu/store/9z95jms1r801z1kxpiq5xw594cxaw5jx-guile-wrapper/bin/guile core

[...]

Core was generated by `/gnu/store/9z95jms1r801z1kxpiq5xw594cxaw5jx-guile-wrapper/bin/guile --no-auto-c'.
Program terminated with signal SIGSEGV, Segmentation fault.
#0 __vfprintf_internal (s=0x0, format=0x7f9da91744e2 "In execvp of %s: %s\n",
ap=ap@entry=0x7ffd286a3c78, mode_flags=mode_flags@entry=0) at vfprintf-internal.c:1359
1359 vfprintf-internal.c: No such file or directory.
(gdb) bt
#0 __vfprintf_internal (s=0x0, format=0x7f9da91744e2 "In execvp of %s: %s\n",
ap=ap@entry=0x7ffd286a3c78, mode_flags=mode_flags@entry=0) at vfprintf-internal.c:1359
#1 0x00007f9da8ed3589 in __fprintf (stream=<optimized out>, format=<optimized out>)
at fprintf.c:32
#2 0x00007f9da913fd93 in ?? ()
from /gnu/store/1jgcbdzx2ss6xv59w55g3kr3x4935dfb-guile-3.0.8/lib/libguile-3.0.so.1
#3 0x00007f9da9140e01 in scm_system_star ()
from /gnu/store/1jgcbdzx2ss6xv59w55g3kr3x4935dfb-guile-3.0.8/lib/libguile-3.0.so.1

[...]

This is because the fdopen(2, "a") call in ‘start_child’ returns NULL:

Toggle snippet (6 lines)
$ ltrace -f -e fdopen /bin/sh -c 'guix import texlive abstract'
[pid 22937] --- Called exec() ---
[pid 22945] libguile-3.0.so.1->fdopen(2, 0x7fddfd364a4a, -1, -112) = 0
[pid 22945] --- SIGSEGV (Segmentation fault) ---

It can be reproduced like this:

Toggle snippet (8 lines)
scheme@(guile-user)> (parameterize ((current-output-port (current-error-port))) (system* "sdfsdf"))
$1 = 139
scheme@(guile-user)> (status:term-sig $1)
$2 = 11
scheme@(guile-user)> (version)
$3 = "3.0.8"

Fixed in Guile commit 56b1ea9002d2d3967b597aa0ee7595e815b21f23.

Back to the original issue Jack and Hugo reported: you need to add ‘svn’
to $PATH to make things work. :-)

Thanks,
Ludo’.
?