0
0
Fork 1
mirror of https://mau.dev/maunium/synapse.git synced 2024-12-14 17:53:51 +01:00

Merge pull request #4033 from intelfx/py37-hotfixes

py3: python3.7 hotfixes
This commit is contained in:
Amber Brown 2018-10-15 20:13:19 +11:00 committed by GitHub
commit f9ce1b4eb0
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
3 changed files with 5 additions and 3 deletions

2
changelog.d/4033.bugfix Normal file
View file

@ -0,0 +1,2 @@
Synapse now starts on Python 3.7.
_All_ workers now start on Python 3.

View file

@ -68,7 +68,7 @@ class PresenceStatusStubServlet(ClientV1RestServlet):
"Authorization": auth_headers, "Authorization": auth_headers,
} }
result = yield self.http_client.get_json( result = yield self.http_client.get_json(
self.main_uri + request.uri, self.main_uri + request.uri.decode('ascii'),
headers=headers, headers=headers,
) )
defer.returnValue((200, result)) defer.returnValue((200, result))
@ -125,7 +125,7 @@ class KeyUploadServlet(RestServlet):
"Authorization": auth_headers, "Authorization": auth_headers,
} }
result = yield self.http_client.post_json_get_json( result = yield self.http_client.post_json_get_json(
self.main_uri + request.uri, self.main_uri + request.uri.decode('ascii'),
body, body,
headers=headers, headers=headers,
) )

View file

@ -219,7 +219,7 @@ def filter_events_for_server(store, server_name, events):
# Whatever else we do, we need to check for senders which have requested # Whatever else we do, we need to check for senders which have requested
# erasure of their data. # erasure of their data.
erased_senders = yield store.are_users_erased( erased_senders = yield store.are_users_erased(
e.sender for e in events, (e.sender for e in events),
) )
def redact_disallowed(event, state): def redact_disallowed(event, state):