Package: graphite-web Version: 1.1.4-1 Severity: important Dear Maintainer,
when I upgraded my graphite-web installation on Debian testing from 1.0.2+debian-2.1 to the current 1.1.4-1 version, graphite-web stopped working. I'm using Apache 2.4, my configuration is exactly identical to the sample configuration in /usr/share/graphite-web/apache2-graphite.conf After the upgrade now all requests result in HTTP status 500: 192.168.x.y - - [22/Dec/2018:14:54:03 +0100] "POST /render HTTP/1.1" 500 707 "https://grafana.DOMAIN/dashboard/db/homematic?refresh=1m&orgId=1" "Mozilla/5.0 (Macintosh; Intel Mac OS X 10_10_5) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/71.0.3578.98 Safari/537.36" 192.168.x.y - - [22/Dec/2018:15:00:13 +0100] "GET / HTTP/1.1" 500 707 "-" "Mozilla/5.0 (Macintosh; Intel Mac OS X 10_10_5) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/71.0.3578.98 Safari/537.36" The following error is logged in the apache error log: [Sat Dec 22 15:00:14.306438 2018] [wsgi:error] [pid 8566] [remote 192.168.145.2:50554] mod_wsgi (pid=8566): Target WSGI script '/usr/share/graphite-web/graphite.wsgi' cannot be loaded as Python module. [Sat Dec 22 15:00:14.306473 2018] [wsgi:error] [pid 8566] [remote 192.168.145.2:50554] mod_wsgi (pid=8566): Exception occurred processing WSGI script '/usr/share/graphite-web/graphite.wsgi'. [Sat Dec 22 15:00:14.306496 2018] [wsgi:error] [pid 8566] [remote 192.168.145.2:50554] Traceback (most recent call last): [Sat Dec 22 15:00:14.306518 2018] [wsgi:error] [pid 8566] [remote 192.168.145.2:50554] File "/usr/share/graphite-web/graphite.wsgi", line 14, in <module> [Sat Dec 22 15:00:14.306550 2018] [wsgi:error] [pid 8566] [remote 192.168.145.2:50554] application = get_wsgi_application() [Sat Dec 22 15:00:14.306562 2018] [wsgi:error] [pid 8566] [remote 192.168.145.2:50554] File "/usr/lib/python2.7/dist-packages/django/core/wsgi.py", line 13, in get_wsgi_application [Sat Dec 22 15:00:14.306582 2018] [wsgi:error] [pid 8566] [remote 192.168.145.2:50554] django.setup(set_prefix=False) [Sat Dec 22 15:00:14.306593 2018] [wsgi:error] [pid 8566] [remote 192.168.145.2:50554] File "/usr/lib/python2.7/dist-packages/django/__init__.py", line 22, in setup [Sat Dec 22 15:00:14.306625 2018] [wsgi:error] [pid 8566] [remote 192.168.145.2:50554] configure_logging(settings.LOGGING_CONFIG, settings.LOGGING) [Sat Dec 22 15:00:14.306635 2018] [wsgi:error] [pid 8566] [remote 192.168.145.2:50554] File "/usr/lib/python2.7/dist-packages/django/conf/__init__.py", line 56, in __getattr__ [Sat Dec 22 15:00:14.306652 2018] [wsgi:error] [pid 8566] [remote 192.168.145.2:50554] self._setup(name) [Sat Dec 22 15:00:14.306661 2018] [wsgi:error] [pid 8566] [remote 192.168.145.2:50554] File "/usr/lib/python2.7/dist-packages/django/conf/__init__.py", line 41, in _setup [Sat Dec 22 15:00:14.306676 2018] [wsgi:error] [pid 8566] [remote 192.168.145.2:50554] self._wrapped = Settings(settings_module) [Sat Dec 22 15:00:14.306685 2018] [wsgi:error] [pid 8566] [remote 192.168.145.2:50554] File "/usr/lib/python2.7/dist-packages/django/conf/__init__.py", line 110, in __init__ [Sat Dec 22 15:00:14.306699 2018] [wsgi:error] [pid 8566] [remote 192.168.145.2:50554] mod = importlib.import_module(self.SETTINGS_MODULE) [Sat Dec 22 15:00:14.306708 2018] [wsgi:error] [pid 8566] [remote 192.168.145.2:50554] File "/usr/lib/python2.7/importlib/__init__.py", line 37, in import_module [Sat Dec 22 15:00:14.306724 2018] [wsgi:error] [pid 8566] [remote 192.168.145.2:50554] __import__(name) [Sat Dec 22 15:00:14.306744 2018] [wsgi:error] [pid 8566] [remote 192.168.145.2:50554] ImportError: No module named graphite.settings When I replaced libapache2-mod-wsgi with libapache2-mod-wsgi-py3 (which made sense, since the Changelog mentioned switching to Python 3), everything started working again. So maybe you should consider adding an entry to NEWS.Debian I'm not sure what I missed when performing the upgrade. The file /usr/share/doc/graphite-web/README.Debian still mentions the Python 2 module: | Quick manual to use Graphite with Apache: | ----------------------------------------- | | # Install Apache module wsgi: | apt-get install libapache2-mod-wsgi apache2 Regards, Sven -- System Information: Debian Release: buster/sid APT prefers testing APT policy: (650, 'testing'), (1, 'experimental') Architecture: amd64 (x86_64) Kernel: Linux 4.18.0-3-amd64 (SMP w/12 CPU cores) Locale: LANG=C, LC_CTYPE=de_DE.UTF-8 (charmap=UTF-8), LANGUAGE=C (charmap=UTF-8) Shell: /bin/sh linked to /bin/bash Init: systemd (via /run/systemd/system) LSM: AppArmor: enabled Versions of packages graphite-web depends on: ii adduser 3.118 ii python 2.7.15-3 ii python3 3.7.1-2 ii python3-cairo 1.16.2-1+b1 ii python3-cairocffi 0.7.2-2.1 ii python3-django 1:1.11.17-2 ii python3-django-tagging 1:0.4.5-1 ii python3-pyparsing 2.2.0+dfsg1-2 ii python3-simplejson 3.15.0-1+b1 ii python3-six 1.12.0-1 ii python3-tz 2018.7-1 ii python3-urllib3 1.24-1 ii python3-whisper 1.1.4-2 graphite-web recommends no packages. Versions of packages graphite-web suggests: ii graphite-carbon 1.1.4-2 pn libapache2-mod-wsgi-py3 <none> pn python3-ldap <none> pn python3-memcache <none> pn python3-mysqldb <none> -- debconf-show failed