Linux Mastering Development Ubuntu

Target WSGI script ‘/var/www/FlaskApp/flaskapp.wsgi’ cannot be loaded as Python module

Stuck here for days

mod_wsgi (pid=16615): Target WSGI script '/var/www/FlaskApp/flaskapp.wsgi' cannot be loaded as Python module.
mod_wsgi (pid=16615): Exception occurred processing WSGI script '/var/www/FlaskApp/flaskapp.wsgi'.
Traceback (most recent call last):
File "/var/www/FlaskApp/flaskapp.wsgi", line 7, in <module>
from FlaskApp import app as application
File "/var/www/FlaskApp/FlaskApp/", line 6, in <module>
from Recognition import testCode,trainCode
File "/home/example_2019/", line 2, in <module>
from sklearn import neighbors
File "/usr/local/lib/python3.6/dist-packages/sklearn/", line 75, in <module>
[Tue Mar 17 14:00:00.971169 2020] [wsgi:error] [pid 16615:tid 140452233717504] [client]     from . import __check_build
File "/usr/local/lib/python3.6/dist-packages/sklearn/__check_build/", line 46, in <module>
File "/usr/local/lib/python3.6/dist-packages/sklearn/__check_build/", line 41, in raise_build_error
%s""" % (e, local_dir, ''.join(dir_content).strip(), msg))
ImportError: No module named _check_build
Contents of /usr/local/lib/python3.6/dist-packages/sklearn/__check_build:             
It seems that scikit-learn has not been built correctly.
If you have installed scikit-learn from source, please do not forget
to build the package before using it: run `python install` or
`make` in the source directory.
If you have used an installer, please check that it is suited for your
Python version, your operating system and your platform.

Leave a Reply

Your email address will not be published. Required fields are marked *