Web server reporting: "ModuleNotFoundError: No module named 'pyodbc' "
Working on getting the code in /opt/dqsegdb/python_server/src/
Python 3-compatible. WSGI has already been updated to the P3 version in testing (on segments-dev2, by yum-installing python3-mod_wsgi
and yum-removing python27-mod_wsgi
, leaving only mod_wsgi_python3.so
as the only WSGI module in /etc/httpd/modules/
and leaving 10-wsgi-python3.conf
as the only WSGI configuration file in /etc/httpd/conf.modules.d/
).
Running ligolw_segment_query_dqsegdb --ping --segment-url https://segments-dev2.ligo.org
or ligolw_segment_query_dqsegdb --ping --segment-url http://segments-dev2.ldas.cit
from segments-dev produces an error ending in urllib.error.HTTPError: HTTP Error 500: Internal Server Error
on that machine and an error in the httpd log files on segments-dev2 including these lines:
mod_wsgi (pid=10908): Failed to exec Python script file '/opt/dqsegdb/python_server/src/application.py'.
mod_wsgi (pid=10908): Exception occurred processing WSGI script '/opt/dqsegdb/python_server/src/application.py'.
[...]
ModuleNotFoundError: No module named 'pyodbc'
yum install pyodbc
reports:
[...]
Package pyodbc-3.0.10-1.el7.x86_64 already installed and latest version
Nothing to do
Note that on PyPI ( https://pypi.org/project/pyodbc/ ), pyodbc is on version 4.0.35, as of 15 Nov. 2022.