Problem with Using SageMath as a Python Package

131 views
Skip to first unread message

Alexander Verner

unread,
Mar 21, 2025, 1:00:39 AM3/21/25
to sage-devel


Hello,

I'm experiencing difficulties with using SageMath as a Python package. In particular, to see why Groebner basis computation in a specific problem of mine takes ages, I'd like to follow the underlying code line-by-line. I compiled SageMath 10.5 on WSL Ubuntu 22.04. Then, following the instructions on this page, I installed Tkinter, reinstalled the SageMath version of Python, started SageMath Python 3.12.5 with "sage -python", then told the interpreter to process "from sage.all import *". It failed with "No module named 'sage'". The directory I run sage from is "~/sage/" and it's the one that contains both executables such as "sage", "bootstrap", "configure", and directories such as "logs", "src", "tools", etc. Inside the "src" directory, there's another directory called "sage", which contains "all.py" and other Python files with the source code. I tried to change the working directory in Python to the "src" directory and import "sage.all" again, but it failed too, this time complaining about missing "cysignals" package in SagMath Python.

Any help with this issue would be much appreciated.

Regards,
Alexander.

Dima Pasechnik

unread,
Mar 21, 2025, 1:13:07 AM3/21/25
to sage-devel
We're discussing this  issue here: https://github.com/sagemath/sage/issues/39740
which seems to progress forward
Reply all
Reply to author
Forward
0 new messages