2 files changed, 2 insertions, 4 deletions
diff --git a/synapse/python_dependencies.py b/synapse/python_dependencies.py
index 9692f0bf75..7dfa78dadb 100644
--- a/synapse/python_dependencies.py
+++ b/synapse/python_dependencies.py
@@ -67,7 +67,7 @@ REQUIREMENTS = [
"pymacaroons>=0.13.0",
"msgpack>=0.5.0",
"phonenumbers>=8.2.0",
- "six>=1.12",
+ "six>=1.10",
# prometheus_client 0.4.0 changed the format of counter metrics
# (cf https://github.com/matrix-org/synapse/issues/4001)
"prometheus_client>=0.0.18,<0.4.0",
diff --git a/synapse/rest/client/v2_alpha/account_validity.py b/synapse/rest/client/v2_alpha/account_validity.py
index 98f7c60016..8091b78285 100644
--- a/synapse/rest/client/v2_alpha/account_validity.py
+++ b/synapse/rest/client/v2_alpha/account_validity.py
@@ -15,8 +15,6 @@
import logging
-from six import ensure_binary
-
from twisted.internet import defer
from synapse.api.errors import AuthError, SynapseError
@@ -65,7 +63,7 @@ class AccountValidityRenewServlet(RestServlet):
request.setResponseCode(status_code)
request.setHeader(b"Content-Type", b"text/html; charset=utf-8")
request.setHeader(b"Content-Length", b"%d" % (len(response),))
- request.write(ensure_binary(response))
+ request.write(response.encode("utf8"))
finish_request(request)
defer.returnValue(None)
|