-
Notifications
You must be signed in to change notification settings - Fork 19
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Different error when run the pytest #45
Comments
“ Usually I run the tests in a It should also be possible to run without a virtual environment. Have you tried running it from the install directory
or using a PYTHONPATH?
|
Thanks for your reply @douglasbagnall
After done some research, I found that joblib v0.13.2 (installed version) fails in python 3.8 (installed version). I upgrade the joblib to version 0.14.0, via Run the test again, I got those: test/test_webapp.py .......s.ss..............x [100%] ============================================================================================================= warnings summary ============================================================================================================== ../env/lib/python3.8/site-packages/botocore/vendored/requests/packages/urllib3/_collections.py:1 -- Docs: https://docs.pytest.org/en/stable/warnings.html Still not the same error mentioned on instruction docs, and I found that the docs was release on 15 Jan 2020, might be out of date. Especially for requirements.txt file, from docs it said tensorflow works with the older 1.14, is that works only for v1.14 and not newer? I have got version 2.4.3 installed. I will attached the the result of From the issue ticket #8 , it support up to Moodle version 3.8dev, how about Moodle V3.9.7 and python version 3.x please, as you can from above, my current python version is 3.8.10. |
Hi Star! - Great to see an interest from LU in using Moodle's machine learning analytics! Yes, the version we're running here at Catalyst supports 3.9.7 (UC are still running 3.9) keep in mind that HQ are in the process of rebuilding and updating the official builds in MDL-70887 too. Feel free to reach out privately if you're still stuck and can't get it running - you could look at using our hosted tensorflow server or getting us to set it up on a VM for you. thanks! |
HI @chens2i , Have you tried to run with different python version? I see CI in github uses python3.7 Cheers, |
To clarify, the mlbackend itself runs under newer versions (I use 3.8 and 3.9 for development), but the dependencies in requirements.txt and setup.py are fragile and imperfectly maintained. So Ilya is right. This is a good thing to look at. The approach I usually use in these situations is to remove For example, your problem here (from https://github.com/moodlehq/moodle-mlbackend-python/files/7239839/requirements.result.txt):
looks to be that something (e.g. Having said that, I am not a packaging person. |
After follow the instruction, all mentioned requirement packages has been satisfied, until Run the test.
(env) root@t-cisubuntu20:/opt# type -a python
python is /opt/env/bin/python
(env) root@t-cisubuntu20:/opt# type -a pytest
pytest is /opt/env/bin/pytest
(env) root@t-cisubuntu20:/opt# python3 -m pytest
============================================================================================================ test session starts ============================================================================================================
platform linux -- Python 3.8.10, pytest-6.2.5, py-1.10.0, pluggy-1.0.0
rootdir: /opt
plugins: flask-1.2.0
collected 0 items / 1 error
================================================================================================================== ERRORS ===================================================================================================================
_______________________________________________________________________________________ ERROR collecting moodle-mlbackend-python/test/test_webapp.py ________________________________________________________________________________________
ImportError while importing test module '/opt/moodle-mlbackend-python/test/test_webapp.py'.
Hint: make sure your test modules/packages have valid Python names.
Traceback:
/usr/lib/python3.8/importlib/init.py:127: in import_module
return _bootstrap._gcd_import(name[level:], package, level)
moodle-mlbackend-python/test/test_webapp.py:60: in
import webapp
E ModuleNotFoundError: No module named 'webapp'
========================================================================================================== short test summary info ==========================================================================================================
ERROR moodle-mlbackend-python/test/test_webapp.py
!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!! Interrupted: 1 error during collection !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
============================================================================================================= 1 error in 0.23s ==============================================================================================================
From the docs, If you hit a different error at this point, something is missing.
What am I missing? Go ahead for next step?
The text was updated successfully, but these errors were encountered: