Sage 9.3 for Windows crashing

383 views
Skip to first unread message

Fernando Q. Gouvea

unread,
Sep 22, 2021, 2:36:41 PM9/22/21
to sage-s...@googlegroups.com

I just had SageMath 9.2 crash, so I tried installing 9.3. Alas, I get the same problem. The offending command is pretty innocuous:

sage: plot(ln(1+x),(-1,5))

The Sage window then crashes. In the notebook I get a message that the kernel just died. Running it in the Sage Terminal, sage crashes and leaves this message behind:

------------------------------------------------------------------------
Unhandled SIGSEGV: A segmentation fault occurred.
This probably occurred because a *compiled* module has a bug
in it and is not properly wrapped with sig_on(), sig_off().
Python will now terminate.
------------------------------------------------------------------------
/opt/sagemath-9.3/src/bin/sage-python: line 2:  1535 Segmentation fault      (core dumped) sage -python "$@"

Any ideas as to what is going on?

Fernando


-- 
==================================================================
Fernando Q. Gouvea                
Carter Professor of Mathematics  
Colby College                    
Mayflower Hill 5836        
Waterville, ME 04901	   
fqgo...@colby.edu	   http://www.colby.edu/~fqgouvea

Humility engenders learning because it beats back the arrogance
that puts blinders on. It leaves you open for truths to reveal
themselves. You don't stand in your own way.
  -- Wynton Marsalis

William Stein

unread,
Sep 22, 2021, 2:47:34 PM9/22/21
to sage-support
On Wed, Sep 22, 2021 at 11:36 AM Fernando Q. Gouvea <fqgo...@colby.edu> wrote:
>
> I just had SageMath 9.2 crash, so I tried installing 9.3. Alas, I get the same problem. The offending command is pretty innocuous:
>
> sage: plot(ln(1+x),(-1,5))
>
> The Sage window then crashes. In the notebook I get a message that the kernel just died. Running it in the Sage Terminal, sage crashes and leaves this message behind:
>
> ------------------------------------------------------------------------
> Unhandled SIGSEGV: A segmentation fault occurred.
> This probably occurred because a *compiled* module has a bug
> in it and is not properly wrapped with sig_on(), sig_off().
> Python will now terminate.
> ------------------------------------------------------------------------
> /opt/sagemath-9.3/src/bin/sage-python: line 2: 1535 Segmentation fault (core dumped) sage -python "$@"
>
> Any ideas as to what is going on?

Do lots of things you try cause problems like this or is it just plotting?

E.g., what if you do some basic arithmetic with p-adic numbers, e.g.,
some examples from here:

https://doc.sagemath.org/html/en/reference/padics/sage/rings/padics/tutorial.html

(Sorry, I can't help asking that given that I learned all about
p-adics from your book decades ago...)

>
> Fernando
>
>
> --
> ==================================================================
> Fernando Q. Gouvea
> Carter Professor of Mathematics
> Colby College
> Mayflower Hill 5836
> Waterville, ME 04901
> fqgo...@colby.edu http://www.colby.edu/~fqgouvea
>
> Humility engenders learning because it beats back the arrogance
> that puts blinders on. It leaves you open for truths to reveal
> themselves. You don't stand in your own way.
> -- Wynton Marsalis
>
> --
> You received this message because you are subscribed to the Google Groups "sage-support" group.
> To unsubscribe from this group and stop receiving emails from it, send an email to sage-support...@googlegroups.com.
> To view this discussion on the web visit https://groups.google.com/d/msgid/sage-support/e587c471-9ffa-4364-5fa2-fbf40d63e7d6%40colby.edu.



--
William (http://wstein.org)

William Stein

unread,
Sep 22, 2021, 3:50:12 PM9/22/21
to sage-support
---------- Forwarded message ---------
From: Fernando Q. Gouvea <fqgo...@colby.edu>
Date: Wed, Sep 22, 2021 at 12:26 PM
Subject: Re: [sage-support] Sage 9.3 for Windows crashing
To: William Stein <wst...@gmail.com>


At this point, only plotting has caused the problem. For example:

sage: K=Qp(7)
sage: K
7-adic Field with capped relative precision 20
sage: a=K(8)
sage: a
1 + 7 + O(7^20)
sage: sqrt(a)
1 + 4*7 + 2*7^2 + 7^3 + 3*7^4 + 2*7^5 + 4*7^6 + 2*7^7 + 5*7^8 + 7^11 +
4*7^12 + 4*7^13 + 6*7^14 + 2*7^15 + 4*7^16 + 4*7^17 + 5*7^18 + O(7^20)
sage: log(a)
7 + 3*7^2 + 7^3 + 6*7^4 + 5*7^5 + 2*7^6 + 7^7 + 5*7^8 + 4*7^9 + 4*7^10 +
2*7^11 + 5*7^12 + 7^13 + 5*7^14 + 6*7^15 + 2*7^16 + 2*7^17 + 2*7^18 +
7^19 + O(7^20)

That all works fine.

Fernando
What garlic is to food, insanity is to art.



--
William (http://wstein.org)

Fernando Gouvea

unread,
Sep 22, 2021, 5:12:02 PM9/22/21
to sage-s...@googlegroups.com

Update: the problem is machine-dependent. On one Dell laptop, plot works with no problem. On a different one, big crash.

Fernando

-- 
=============================================================
Fernando Q. Gouvea         http://www.colby.edu/~fqgouvea
Carter Professor of Mathematics
Dept. of Mathematics and Statistics
Colby College              
5836 Mayflower Hill        
Waterville, ME 04901       

We receive the deepest truths only when we're patient enough
-- and stable enough and docile enough -- to allow ourselves
to be taught them.
  -- R. R. Reno, in "Piety's Rightful Claim"

Dima Pasechnik

unread,
Sep 23, 2021, 5:49:40 AM9/23/21
to sage-support
On Wed, Sep 22, 2021 at 10:12 PM Fernando Gouvea <fqgo...@colby.edu> wrote:

Update: the problem is machine-dependent. On one Dell laptop, plot works with no problem. On a different one, big crash.


We see this with other operating systems, too. Hopefully fixed in 9.4, see
 

Matthias Koeppe

unread,
Sep 23, 2021, 12:36:45 PM9/23/21
to sage-support
No, the 9.4 binaries have the same problem, as noted in https://wiki.sagemath.org/ReleaseTours/sage-9.4#Availability_as_binaries_and_in_distributions

We have two tickets in the 9.5 development series that aim to fix this problem:
https://trac.sagemath.org/ticket/32488 (which will be in 9.5.beta2)

Kai Weber

unread,
Nov 26, 2021, 12:20:44 PM11/26/21
to sage-support
Hi, I do have the same problem. I can't use plot() - not even a plot(1) with a constant . I am running Sage 9.3 on Windows 11 and Surface Book 3. I understand that the problem will not be solved until Sage 9.5. But I need the plot() function now. Is there a workaround or another way to plot data?

Thanks for your answers in advance,

Cheers, Kai

Dima Pasechnik

unread,
Nov 26, 2021, 12:22:02 PM11/26/21
to sage-support


On Fri, 26 Nov 2021, 17:20 Kai Weber, <aikj...@gmail.com> wrote:
Hi, I do have the same problem. I can't use plot() - not even a plot(1) with a constant . I am running Sage 9.3 on Windows 11 and Surface Book 3. I understand that the problem will not be solved until Sage 9.5. But I need the plot() function now. Is there a workaround or another way to plot data?

Does it work in a Jupyter notebook?

Fernando Gouvea

unread,
Nov 26, 2021, 1:13:18 PM11/26/21
to sage-s...@googlegroups.com

Not on my machine. I even tried something like P=plot(something) followed by P.save('filename'). The assignment works fine, but when it tries to save the Sage kernel crashes.

The only workaround I have found is using SageCell. But that is not very convenient if I need to save the result.

Fernando

-- 
=============================================================
Fernando Q. Gouvea         http://www.colby.edu/~fqgouvea
Carter Professor of Mathematics
Dept. of Mathematics
Colby College              
5836 Mayflower Hill        
Waterville, ME 04901       

How was it that in the weeks since her marriage, Dorothea had not
distinctly observed but felt with a stifling depression, that the
large vistas and wide fresh air which she had dreamed of finding in
her husband's mind were replaced by ante-rooms and winding passages
which seemed to lead nowither?
  -- George Eliot, in Middlemarch

Reply all
Reply to author
Forward
0 new messages