Sagemath в Ubuntu 20.04 - предупреждения при установке и невозможность запуска sagemath notebook

Я установил sagemath из репозитория в Ubuntu 20.04:

sudo apt-get install sagemath

Теперь при установке sagemath в Ubuntu 20.04 я получаю следующие предупреждения:

Setting up python3-cvxopt (1.2.3+dfsg-2build1) ...
/usr/lib/python3/dist-packages/cvxopt/__init__.py:136: SyntaxWarning: "is" with a literal. Did you mean "=="?
  if val is 0: val = None
/usr/lib/python3/dist-packages/cvxopt/coneprog.py:4043: SyntaxWarning: "is" with a literal. Did you mean "=="?
  if status is 'optimal' or dcost <= 0.0:
/usr/lib/python3/dist-packages/cvxopt/coneprog.py:4061: SyntaxWarning: "is" with a literal. Did you mean "=="?
  if status is 'optimal' or pcost >= 0.0:
/usr/lib/python3/dist-packages/cvxopt/misc.py:916: SyntaxWarning: "is" with a literal. Did you mean "=="?
  if diag is 'N':
/usr/lib/python3/dist-packages/cvxopt/msk.py:105: SyntaxWarning: "is" with a literal. Did you mean "=="?
  if m is 0: raise ValueError("m cannot be 0")
/usr/lib/python3/dist-packages/cvxopt/msk.py:178: SyntaxWarning: "is not" with a literal. Did you mean "!="?
  if p is not 0:
/usr/lib/python3/dist-packages/cvxopt/msk.py:314: SyntaxWarning: "is" with a literal. Did you mean "=="?
  if cdim is 0: raise ValueError("ml+mq+ms cannot be 0")
/usr/lib/python3/dist-packages/cvxopt/msk.py:750: SyntaxWarning: "is" with a literal. Did you mean "=="?
  if m+p is 0: raise ValueError("m + p must be greater than 0")
/usr/lib/python3/dist-packages/cvxopt/msk.py:815: SyntaxWarning: "is not" with a literal. Did you mean "!="?
  if m is not 0:
/usr/lib/python3/dist-packages/cvxopt/msk.py:823: SyntaxWarning: "is not" with a literal. Did you mean "!="?
  if p is not 0:
/usr/lib/python3/dist-packages/cvxopt/msk.py:904: SyntaxWarning: "is" with a literal. Did you mean "=="?
  if m is 0: raise ValueError("m cannot be 0")
/usr/lib/python3/dist-packages/cvxopt/printing.py:43: SyntaxWarning: "is" with a literal. Did you mean "=="?
  if width*height is 0: return ""
/usr/lib/python3/dist-packages/cvxopt/printing.py:44: SyntaxWarning: "is" with a literal. Did you mean "=="?
  if len(X) is 0: return ""
/usr/lib/python3/dist-packages/cvxopt/printing.py:101: SyntaxWarning: "is" with a literal. Did you mean "=="?
  if width*height is 0: return ""

Позже при установке код ошибки повторяется снова:

Setting up python3-sagetex (3.4+ds-1) ...
/usr/lib/python3/dist-packages/sagetexparse.py:135: SyntaxWarning: "is not" with a literal. Did you mean "!="?
  if t.format is not '':

При запуске sagemath и попытке запустить записную книжку я получаю следующий код ошибки:

┌────────────────────────────────────────────────────────────────────┐
│ SageMath version 9.0, Release Date: 2020-01-01                     │
│ Using Python 3.8.5. Type "help()" for help.                        │
└────────────────────────────────────────────────────────────────────┘
Setting permissions of DOT_SAGE directory so only you can read and write it.
sage: notebook()                                                                
---------------------------------------------------------------------------
ModuleNotFoundError                       Traceback (most recent call last)
<ipython-input-1-b5959bb24428> in <module>
----> 1 notebook()

/usr/lib/python3/dist-packages/sage/misc/lazy_import.pyx in sage.misc.lazy_import.LazyImport.__call__ (build/cythonized/sage/misc/lazy_import.c:3684)()
    351             True
    352         """
--> 353         return self.get_object()(*args, **kwds)
    354 
    355     def __repr__(self):

/usr/lib/python3/dist-packages/sage/misc/lazy_import.pyx in sage.misc.lazy_import.LazyImport.get_object (build/cythonized/sage/misc/lazy_import.c:2347)()
    186         if likely(self._object is not None):
    187             return self._object
--> 188         return self._get_object()
    189 
    190     cpdef _get_object(self):

/usr/lib/python3/dist-packages/sage/misc/lazy_import.pyx in sage.misc.lazy_import.LazyImport._get_object (build/cythonized/sage/misc/lazy_import.c:2586)()
    218         elif self._at_startup and not startup_guard:
    219             print('Option ``at_startup=True`` for lazy import {0} not needed anymore'.format(self._name))
--> 220         self._object = getattr(__import__(self._module, {}, {}, [self._name]), self._name)
    221         name = self._as_name
    222         if self._deprecation is not None:

ModuleNotFoundError: No module named 'sagenb'
sage:                                                  

Я не знаю, как это исправить. Моя версия python - 3.8.5.

1
задан 2 January 2021 в 13:11

0 ответов

Другие вопросы по тегам:

Похожие вопросы: