ImportError: Import by filename is not supported.
on ubuntu 20.10 trying to import a python file on my mod_python project SiteBuilder=apache.import_module('~/lib/core/SiteBuilder.py')
i get this error :
Mod_python error: "PythonHandler main"
Traceback (most recent call last):
File "/usr/local/lib/python2.7/dist-packages/mod_python/apache.py", line 356, in HandlerDispatch log=debug)
File "/usr/local/lib/python2.7/dist-packages/mod_python/apache.py", line 633, in import_module module = importlib.import_module(module_name)
File "/usr/lib/python2.7/importlib/init.py", line 37, in import_module import(name)
File "/var/sites/kaotonik/main.py", line 3, in
File "/usr/local/lib/python2.7/dist-packages/mod_python/apache.py", line 633, in import_module module = importlib.import_module(module_name)
File "/usr/lib/python2.7/importlib/init.py", line 37, in import_module import(name)
ImportError: Import by filename is not supported.
the project works on ubuntu 18.04