Re: R-devel crashes when can't find function
Toby Hocking via ESS-help <[email protected]> Wed, 5 Feb 2025 22:46:28 +0100
| Newsgroups | gmane.emacs.ess.general |
|---|---|
| Message-ID | <CALK03d1RFvpE5QNbQQjvePs9d3_bMvpJiWWd9t30EBk+t3h8Uw@mail.gmail.com> |
Thanks Seb I confirm that option is responsible for the crash: (base) tdhock@tdhock-MacBook:~$ R/R-devel/bin/R -e 'foo()' R Under development (unstable) (2025-02-02 r87676) -- "Unsuffered Consequences" Copyright (C) 2025 The R Foundation for Statistical Computing Platform: x86_64-pc-linux-gnu R est un logiciel libre livr=C3=A9 sans AUCUNE GARANTIE. Vous pouvez le redistribuer sous certaines conditions. Tapez 'license()' ou 'licence()' pour plus de d=C3=A9tails. R est un projet collaboratif avec de nombreux contributeurs. Tapez 'contributors()' pour plus d'information et 'citation()' pour la fa=C3=A7on de le citer dans les publications. Tapez 'demo()' pour des d=C3=A9monstrations, 'help()' pour l'aide en ligne ou 'help.start()' pour obtenir l'aide au format HTML. Tapez 'q()' pour quitter R. Le chargement a n=C3=A9cessit=C3=A9 le package : grDevices > foo() Erreur dans foo() : impossible de trouver la fonction "foo" Ex=C3=A9cution arr=C3=AAt=C3=A9e (base) tdhock@tdhock-MacBook:~$ R/R-devel/bin/R -e 'options(show.error.locations =3D TRUE);foo()' R Under development (unstable) (2025-02-02 r87676) -- "Unsuffered Consequences" Copyright (C) 2025 The R Foundation for Statistical Computing Platform: x86_64-pc-linux-gnu R est un logiciel libre livr=C3=A9 sans AUCUNE GARANTIE. Vous pouvez le redistribuer sous certaines conditions. Tapez 'license()' ou 'licence()' pour plus de d=C3=A9tails. R est un projet collaboratif avec de nombreux contributeurs. Tapez 'contributors()' pour plus d'information et 'citation()' pour la fa=C3=A7on de le citer dans les publications. Tapez 'demo()' pour des d=C3=A9monstrations, 'help()' pour l'aide en ligne ou 'help.start()' pour obtenir l'aide au format HTML. Tapez 'q()' pour quitter R. Le chargement a n=C3=A9cessit=C3=A9 le package : grDevices > options(show.error.locations =3D TRUE);foo() *** caught segfault *** address 0x180, cause 'memory not mapped' An irrecoverable exception occurred. R is aborting now ... Erreur de segmentation (core dumped) On Wed, Feb 5, 2025 at 2:06=E2=80=AFPM Sebastian Meyer <[email protected]> w= rote: > I could reproduce the problem in R-devel. > > It is not an ESS-specific bug: it happens under > `options(show.error.locations =3D TRUE)`, which is unset by default but > set by ESS. The following is sufficient to trigger the segfault: > > options(show.error.locations =3D TRUE) > foo() > > I guess the issue is related to PR#18841 > <https://bugs.r-project.org/show_bug.cgi?id=3D18841>, merged last week. I > left a comment there. > > Best, > > Sebastian > > > Am 05.02.25 um 11:25 schrieb Toby Hocking via ESS-help: > > Here is the crash report that I forgot in my original post > > > > =3D=3D34394=3D=3D Memcheck, a memory error detector > > =3D=3D34394=3D=3D Copyright (C) 2002-2017, and GNU GPL'd, by Julian Sew= ard et al. > > =3D=3D34394=3D=3D Using Valgrind-3.18.1 and LibVEX; rerun with -h for c= opyright > info > > =3D=3D34394=3D=3D Command: /home/tdhock/lib/R/bin/exec/R --no-readline > > =3D=3D34394=3D=3D > > > > R Under development (unstable) (2025-02-02 r87676) -- "Unsuffered > > Consequences" > > Copyright (C) 2025 The R Foundation for Statistical Computing > > Platform: x86_64-pc-linux-gnu > > > > R est un logiciel libre livr=C3=A9 sans AUCUNE GARANTIE. > > Vous pouvez le redistribuer sous certaines conditions. > > Tapez 'license()' ou 'licence()' pour plus de d=C3=A9tails. > > > > R est un projet collaboratif avec de nombreux contributeurs. > > Tapez 'contributors()' pour plus d'information et > > 'citation()' pour la fa=C3=A7on de le citer dans les publications. > > > > Tapez 'demo()' pour des d=C3=A9monstrations, 'help()' pour l'aide > > en ligne ou 'help.start()' pour obtenir l'aide au format HTML. > > Tapez 'q()' pour quitter R. > > > > Le chargement a n=C3=A9cessit=C3=A9 le package : grDevices > > > >> foo() > > =3D=3D34394=3D=3D Invalid read of size 8 > > =3D=3D34394=3D=3D at 0x499B77C: R_GetCurrentSrcref (in > > /home/tdhock/lib/R/lib/libR.so) > > =3D=3D34394=3D=3D by 0x4996DD3: verrorcall_dflt (in > > /home/tdhock/lib/R/lib/libR.so) > > =3D=3D34394=3D=3D by 0x49976BD: Rf_errorcall (in > /home/tdhock/lib/R/lib/libR.so) > > =3D=3D34394=3D=3D by 0x4997793: Rf_errorcall_cpy (in > > /home/tdhock/lib/R/lib/libR.so) > > =3D=3D34394=3D=3D by 0x498B205: Rf_findFun3 (in > /home/tdhock/lib/R/lib/libR.so) > > =3D=3D34394=3D=3D by 0x499F8B8: Rf_eval (in /home/tdhock/lib/R/lib/l= ibR.so) > > =3D=3D34394=3D=3D by 0x49A62A2: do_set (in /home/tdhock/lib/R/lib/li= bR.so) > > =3D=3D34394=3D=3D by 0x499FA38: Rf_eval (in /home/tdhock/lib/R/lib/l= ibR.so) > > =3D=3D34394=3D=3D by 0x49F2F75: Rf_ReplIteration (in > > /home/tdhock/lib/R/lib/libR.so) > > =3D=3D34394=3D=3D by 0x49F316B: R_ReplConsole (in > /home/tdhock/lib/R/lib/libR.so) > > =3D=3D34394=3D=3D by 0x49F4BA3: run_Rmainloop (in > /home/tdhock/lib/R/lib/libR.so) > > =3D=3D34394=3D=3D by 0x49F4BB9: Rf_mainloop (in > /home/tdhock/lib/R/lib/libR.so) > > =3D=3D34394=3D=3D Address 0x180 is not stack'd, malloc'd or (recently)= free'd > > =3D=3D34394=3D=3D > > > > *** caught segfault *** > > address 0x180, cause 'memory not mapped' > > > > Possible actions: > > 1: abort (with core dump, if enabled) > > 2: normal R exit > > 3: exit R without saving workspace > > 4: exit R saving workspace > > Selection: > > > > On Wed, Feb 5, 2025 at 11:22=E2=80=AFAM Toby Hocking <[email protected]= > wrote: > > > >> Hi, I'm not sure if this is a bug in R-devel or ESS, but I'm reporting > >> here first. > >> > >> When I type foo() at the commend line, I expect R to give me an error > >> message such as "function foo() not found" and that is what I get using > the > >> command line: > >> (base) tdhock@tdhock-MacBook:~/R/R-devel$ ~/R/R-devel/bin/R --no-save > -e > >> "foo()" > >> > >> R Under development (unstable) (2025-02-02 r87676) -- "Unsuffered > >> Consequences" > >> Copyright (C) 2025 The R Foundation for Statistical Computing > >> Platform: x86_64-pc-linux-gnu > >> > >> R est un logiciel libre livr=C3=A9 sans AUCUNE GARANTIE. > >> Vous pouvez le redistribuer sous certaines conditions. > >> Tapez 'license()' ou 'licence()' pour plus de d=C3=A9tails. > >> > >> R est un projet collaboratif avec de nombreux contributeurs. > >> Tapez 'contributors()' pour plus d'information et > >> 'citation()' pour la fa=C3=A7on de le citer dans les publications. > >> > >> Tapez 'demo()' pour des d=C3=A9monstrations, 'help()' pour l'aide > >> en ligne ou 'help.start()' pour obtenir l'aide au format HTML. > >> Tapez 'q()' pour quitter R. > >> > >> Le chargement a n=C3=A9cessit=C3=A9 le package : grDevices > >>> foo() > >> Erreur dans foo() : impossible de trouver la fonction "foo" > >> Ex=C3=A9cution arr=C3=AAt=C3=A9e > >> > >> But when I do the same thing inside ESS, R crashes. > >> Below I did C-u M-x R -d valgrind RET to start R with valgrind inside > ESS, > >> then I typed foo() RET in the *R* buffer, which crashed. Can anybody > >> reproduce? > >> > >> Can somebody help me reproduce this on the command line? (outside of > ESS) > >> so I can report this to R-devel? > >> > >> Thanks > >> Toby > >> > > > > [[alternative HTML version deleted]] > > > > ______________________________________________ > > [email protected] mailing list > > https://stat.ethz.ch/mailman/listinfo/ess-help > > [[alternative HTML version deleted]] ______________________________________________ [email protected] mailing list https://stat.ethz.ch/mailman/listinfo/ess-help