Open hklarner opened 3 years ago
sage --version
SageMath version 8.1, Release Date: 2017-12-07
Die Readme auf dem Branch fix-sagemath-version sagt
To run the script use: python3 example*.py
aber da bekomme ich einen ModuleNotFoundError:
python3 example1.py
ModuleNotFoundError: No module named 'sage'
Auf dem neuen Branch hast Du nur Tabs gegen Spaces getauscht, oder? Bekomme dieselben Fehler wie zuvor:
git checkout fix-sagemath-version
python3 example1.py
ModuleNotFoundError: No module named 'sage'
sage -python example1.py
TypeError: type.__new__(metaclass) is not safe, use sage.misc.classcall_metaclass.ClasscallMetaclass.__new__()
Ich kann das Docker Image hochfahren. Da läuft Sage 9.0:
docker build -t rschwieger:classifier .
docker run -v ~/IdeaProjects/Classifier-construction-in-Boolean-Networks-using-algebraic-methods:/media -it rschwieger:classifier
root@187ff98181e8:/media# sage --version
SageMath version 9.0, Release Date: 2020-01-01
exit
Das example1.py läuft im Docker Image ohne Fehler durch. Hier die Ergebnisse pro Branch / Befehl.
Auf dem fix-sagemath-version Branch
git checkout fix-sagemath-version
docker run -v ~/IdeaProjects/Classifier-construction-in-Boolean-Networks-using-algebraic-methods:/media -it rschwieger:classifier
cd media
python3 example1.py
...
There are 10 solutions
sage -python example1.py
...
There are 10 solutions
sage -python3 example1.py
...
There are 10 solutions
exit
Auf dem Master Branch:
git checkout master
docker run -v ~/IdeaProjects/Classifier-construction-in-Boolean-Networks-using-algebraic-methods:/media -it rschwieger:classifier
cd media
python3 example1.py
TabError: inconsistent use of tabs and spaces in indentation
python example1.py
bash: python: command not found
sage -python example1.py
TabError: inconsistent use of tabs and spaces in indentation
sage -python3 example1.py
TabError: inconsistent use of tabs and spaces in indentation
to install sagemath 9.0 on ubuntu 18.04 see
Ich habe jetzt den Fix-Branch in den master gemergt, da im Docker die neuere sage Version installiert ist. Und ja, ich hatte im Dockercontainer Probleme mit den Tabs. Deswegen hatte ich die nochmal geändert.
OS: Ubuntu
installed sage with
tried to run an example with
Got error
Have you seen this error before? Any suggestions how to fix it?