From 72df5c4c683bded0ea5dde36ac3beffaedd35dae Mon Sep 17 00:00:00 2001 From: Patrick Cloke Date: Tue, 8 Dec 2020 11:33:58 -0500 Subject: [PATCH 1/2] Fix installing pysaml2. --- changelog.d/8898.misc | 1 + synapse/python_dependencies.py | 6 +++++- 2 files changed, 6 insertions(+), 1 deletion(-) create mode 100644 changelog.d/8898.misc diff --git a/changelog.d/8898.misc b/changelog.d/8898.misc new file mode 100644 index 000000000000..bdb0d40d51e0 --- /dev/null +++ b/changelog.d/8898.misc @@ -0,0 +1 @@ +Add a maximum version for pysaml2 on Python 3.5. diff --git a/synapse/python_dependencies.py b/synapse/python_dependencies.py index c899ca14d3ed..6004e4748e93 100644 --- a/synapse/python_dependencies.py +++ b/synapse/python_dependencies.py @@ -96,7 +96,11 @@ # python 3.5.2, as per https://github.com/itamarst/eliot/issues/418 'eliot<1.8.0;python_version<"3.5.3"', ], - "saml2": ["pysaml2>=4.5.0"], + "saml2": [ + # pysaml2 6.4.0 removed compatibility with Python 3.5. + "pysaml2>=4.5.0,<6.4.0;python_version<'3.6'", + "pysaml2>=4.5.0;python_version>='3.6'", + ], "oidc": ["authlib>=0.14.0"], "systemd": ["systemd-python>=231"], "url_preview": ["lxml>=3.5.0"], From 50ef5ce21312f5494ed8d698dfe097224345d283 Mon Sep 17 00:00:00 2001 From: Patrick Cloke Date: Tue, 8 Dec 2020 12:05:56 -0500 Subject: [PATCH 2/2] Update comment Co-authored-by: Richard van der Hoff <1389908+richvdh@users.noreply.github.com> --- synapse/python_dependencies.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/synapse/python_dependencies.py b/synapse/python_dependencies.py index 6004e4748e93..c97e0df1f53c 100644 --- a/synapse/python_dependencies.py +++ b/synapse/python_dependencies.py @@ -97,7 +97,7 @@ 'eliot<1.8.0;python_version<"3.5.3"', ], "saml2": [ - # pysaml2 6.4.0 removed compatibility with Python 3.5. + # pysaml2 6.4.0 is incompatible with Python 3.5 (see https://github.com/IdentityPython/pysaml2/issues/749) "pysaml2>=4.5.0,<6.4.0;python_version<'3.6'", "pysaml2>=4.5.0;python_version>='3.6'", ],