Traceback (most recent call last):
2026-04-27 08:07:17,160 DEBG 'uwsgi' stdout output:
File "/venv/lib/python3.13/site-packages/alerta/auth/__init__.py", line 21, in register
import saml2 # noqa
^^^^^^^^^^^^
File "/venv/lib/python3.13/site-packages/saml2/__init__.py", line 24, in <module>
from saml2.version import version as __version__
File "/venv/lib/python3.13/site-packages/saml2/version.py", line 1, in <module>
import pkg_resources as _pkg_resources
ModuleNotFoundError: No module named 'pkg_resources'
During handling of the above exception, another exception occurred:
Traceback (most recent call last):
File "/app/wsgi.py", line 2, in <module>
app = create_app()
File "/venv/lib/python3.13/site-packages/alerta/app.py", line 88, in create_app
app.register_blueprint(auth_blueprint)
~~~~~~~~~~~~~~~~~~~~~~^^^^^^^^^^^^^^^^
File "/venv/lib/python3.13/site-packages/flask/sansio/scaffold.py", line 47, in wrapper_func
return f(self, *args, **kwargs)
File "/venv/lib/python3.13/site-packages/flask/sansio/app.py", line 595, in register_blueprint
blueprint.register(self, options)
~~~~~~~~~~~~~~~~~~^^^^^^^^^^^^^^^
File "/venv/lib/python3.13/site-packages/alerta/auth/__init__.py", line 25, in register
raise RuntimeError('Must install pysaml2 to use SAML2 authentication module')
RuntimeError: Must install pysaml2 to use SAML2 authentication module
Issue Summary
The pysaml module isn't working in the official Image
Environment
OS: Linux
API version: 9.1.0
Deployment: Docker
For self-hosted, WSGI environment: nginx/uwsg
Database: Postgres
Server config:
Auth enabled? Yes
Auth provider? SAML
Customer views? No
web UI version: 8.7.1
CLI version: 8.5.3
To Reproduce
Steps to reproduce the behavior:
docker compose logs webExpected behavior
The system should start with the saml module loaded
Additional context

The log says: