Closed DanJack1987 closed 12 months ago
you need to install cyclus
first, or to add the cyclus
install location (the one containing the Python package) in your PYTHONPATH.
you can find more detail here: http://fuelcycle.org and https://github.com/cyclus/cycus
btw:
File "/usr/lib/python2.7/dist-packages/nose/loader.py", line 418, in loadTestsFromName
this mean you have a problem in the /usr/lib/python2.7/dist-packages/nose/loader.py
file so you do have some things related to Python 2.7 installed on your machine.
This is a fresh virtual machine. I have only installed Cyclus, cycamore and cymetric on it as well as dependencies. If I check alternatives python3 is the only option. I believe I did add Cyclus to my python path already. Is there a way to check that?
the problem might come be from nose
,
I am wondering if pip
is not installing python 2.7 package.
Things you can try:
echo $PYTHONPQTH
from cyclus import lib
when I try echo $PYTHONPATH I get nothing.
pip --version pip 20.0.2 from /usr/lib/python3/dist-packages/pip (python 3.8)
from cyclus import lib doesn't return any errors just gives me a new line.
I believe your problem comes from nose. How did you install it. It seems that you have installed a python2 version of nosetest
Cymetric has been updated to use pytest instead of nose (#187), also based on the conversation there might have been incompatible versions of nose and python being used.
@gonuke can this issue be closed?
Closing since our software stack has advanced substantially - please reopen or open a new issue if failures return.
daniel@ubuntu:~/cymetric$ nosetests -w tests/ EEEEEEE
ERROR: Failure: ImportError (No module named cyclus)
Traceback (most recent call last): File "/usr/lib/python2.7/dist-packages/nose/loader.py", line 418, in loadTestsFromName addr.filename, addr.module) File "/usr/lib/python2.7/dist-packages/nose/importer.py", line 47, in importFromPath return self.importFromDir(dir_path, fqname) File "/usr/lib/python2.7/dist-packages/nose/importer.py", line 94, in importFromDir mod = load_module(part_fqname, fh, filename, desc) File "/home/daniel/cymetric/tests/test_cyclus.py", line 9, in
from tools import setup, dbtest
File "/home/daniel/cymetric/tests/tools.py", line 7, in
from cyclus import lib
ImportError: No module named cyclus
====================================================================== ERROR: Failure: ImportError (No module named cymetric)
Traceback (most recent call last): File "/usr/lib/python2.7/dist-packages/nose/loader.py", line 418, in loadTestsFromName addr.filename, addr.module) File "/usr/lib/python2.7/dist-packages/nose/importer.py", line 47, in importFromPath return self.importFromDir(dir_path, fqname) File "/usr/lib/python2.7/dist-packages/nose/importer.py", line 94, in importFromDir mod = load_module(part_fqname, fh, filename, desc) File "/home/daniel/cymetric/tests/test_evaluator.py", line 7, in
from cymetric import evaluator
ImportError: No module named cymetric
====================================================================== ERROR: Failure: ImportError (No module named numpy)
Traceback (most recent call last): File "/usr/lib/python2.7/dist-packages/nose/loader.py", line 418, in loadTestsFromName addr.filename, addr.module) File "/usr/lib/python2.7/dist-packages/nose/importer.py", line 47, in importFromPath return self.importFromDir(dir_path, fqname) File "/usr/lib/python2.7/dist-packages/nose/importer.py", line 94, in importFromDir mod = load_module(part_fqname, fh, filename, desc) File "/home/daniel/cymetric/tests/test_fco_metrics.py", line 9, in
import numpy as np
ImportError: No module named numpy
====================================================================== ERROR: Failure: ImportError (No module named numpy)
Traceback (most recent call last): File "/usr/lib/python2.7/dist-packages/nose/loader.py", line 418, in loadTestsFromName addr.filename, addr.module) File "/usr/lib/python2.7/dist-packages/nose/importer.py", line 47, in importFromPath return self.importFromDir(dir_path, fqname) File "/usr/lib/python2.7/dist-packages/nose/importer.py", line 94, in importFromDir mod = load_module(part_fqname, fh, filename, desc) File "/home/daniel/cymetric/tests/test_filters.py", line 11, in
import numpy as np
ImportError: No module named numpy
====================================================================== ERROR: Failure: ImportError (No module named numpy)
Traceback (most recent call last): File "/usr/lib/python2.7/dist-packages/nose/loader.py", line 418, in loadTestsFromName addr.filename, addr.module) File "/usr/lib/python2.7/dist-packages/nose/importer.py", line 47, in importFromPath return self.importFromDir(dir_path, fqname) File "/usr/lib/python2.7/dist-packages/nose/importer.py", line 94, in importFromDir mod = load_module(part_fqname, fh, filename, desc) File "/home/daniel/cymetric/tests/test_metrics.py", line 12, in
import numpy as np
ImportError: No module named numpy
====================================================================== ERROR: Failure: ImportError (No module named cymetric)
Traceback (most recent call last): File "/usr/lib/python2.7/dist-packages/nose/loader.py", line 418, in loadTestsFromName addr.filename, addr.module) File "/usr/lib/python2.7/dist-packages/nose/importer.py", line 47, in importFromPath return self.importFromDir(dir_path, fqname) File "/usr/lib/python2.7/dist-packages/nose/importer.py", line 94, in importFromDir mod = load_module(part_fqname, fh, filename, desc) File "/home/daniel/cymetric/tests/test_root_metrics.py", line 10, in
from cymetric import root_metrics
ImportError: No module named cymetric
====================================================================== ERROR: Failure: ImportError (No module named numpy)
Traceback (most recent call last): File "/usr/lib/python2.7/dist-packages/nose/loader.py", line 418, in loadTestsFromName addr.filename, addr.module) File "/usr/lib/python2.7/dist-packages/nose/importer.py", line 47, in importFromPath return self.importFromDir(dir_path, fqname) File "/usr/lib/python2.7/dist-packages/nose/importer.py", line 94, in importFromDir mod = load_module(part_fqname, fh, filename, desc) File "/home/daniel/cymetric/tests/test_timeseries.py", line 12, in
import numpy as np
ImportError: No module named numpy
Ran 7 tests in 0.049s