From 3ae42393a646a594b2e70145a69023dfc2363a21 Mon Sep 17 00:00:00 2001 From: Daniele Procida Date: Mon, 20 Apr 2026 05:05:01 +0300 Subject: [PATCH 1/2] Updated psycopg2 --- dashboard/requirements.txt | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/dashboard/requirements.txt b/dashboard/requirements.txt index ebc23e5..1ccb8b6 100644 --- a/dashboard/requirements.txt +++ b/dashboard/requirements.txt @@ -2,7 +2,7 @@ Django==5.2.13 PyYAML==6.0.2 docutils==0.21.2 whitenoise==6.9.0 -psycopg2-binary==2.9.10 +psycopg2-binary==2.9.11 tzdata==2025.1 django-browser-reload==1.18.0 django-tinymce==4.1.0 From bfc38a171b79d802786a9eedb3eca6da753815cf Mon Sep 17 00:00:00 2001 From: Daniele Procida Date: Mon, 20 Apr 2026 05:47:48 +0300 Subject: [PATCH 2/2] Added a testing shim for OIDC. This allows tests in environments that haven't loaded OIDC to continue running. See https://docs.pytest.org/en/latest/reference/fixtures.html#conftest-py-sharing-fixtures-across-multiple-files for notes on shared fixtures. --- dashboard/conftest.py | 28 ++++++++++++++++++++++++++++ 1 file changed, 28 insertions(+) create mode 100644 dashboard/conftest.py diff --git a/dashboard/conftest.py b/dashboard/conftest.py new file mode 100644 index 0000000..67d462a --- /dev/null +++ b/dashboard/conftest.py @@ -0,0 +1,28 @@ +import sys +import types + +from django.http import HttpResponse + + +# Creat a "fake" mozilla_django_oidc.views so that tests will run, +# even if mozilla_django_oidc is not available at import time for +# tests. + +if "mozilla_django_oidc" not in sys.modules: + oidc_module = types.ModuleType("mozilla_django_oidc") + oidc_views_module = types.ModuleType("mozilla_django_oidc.views") + + class _DummyOIDCView: + @classmethod + def as_view(cls): + def _view(request, *args, **kwargs): + return HttpResponse("") + + return _view + + oidc_views_module.OIDCAuthenticationRequestView = _DummyOIDCView + oidc_views_module.OIDCAuthenticationCallbackView = _DummyOIDCView + oidc_views_module.OIDCLogoutView = _DummyOIDCView + oidc_module.views = oidc_views_module + sys.modules["mozilla_django_oidc"] = oidc_module + sys.modules["mozilla_django_oidc.views"] = oidc_views_module \ No newline at end of file