-
Notifications
You must be signed in to change notification settings - Fork 411
Sliding sync: Correctly track which read receipts we have or have not sent down. #17575
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Changes from 28 commits
da5339d
baac6c5
0561c86
c15b8b3
a1b75f7
6b9d244
2e7672d
55feaae
614c0d7
100927d
70d32fb
64310ec
79e80eb
d982efe
b0a5c0e
577370a
27b7a4a
dec5314
5b6755a
9241da0
8a8df06
db4c733
39bece9
161275d
f511576
90ecd9e
49c2f73
53a35e8
7f5bccc
f628b8d
41d37b3
96aaed8
1937ac9
4f08d04
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1 @@ | ||
| Refactor per-connection state in experimental sliding sync handler. |
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1 @@ | ||
| Correctly track read receipts that should be sent down in experimental sliding sync. |
Large diffs are not rendered by default.
| Original file line number | Diff line number | Diff line change |
|---|---|---|
|
|
@@ -45,7 +45,7 @@ | |
| from twisted.test.proto_helpers import MemoryReactorClock | ||
| from twisted.web.server import Site | ||
|
|
||
| from synapse.api.constants import Membership | ||
| from synapse.api.constants import Membership, ReceiptTypes | ||
| from synapse.api.errors import Codes | ||
| from synapse.server import HomeServer | ||
| from synapse.types import JsonDict | ||
|
|
@@ -944,3 +944,15 @@ def initiate_sso_ui_auth( | |
| assert len(p.links) == 1, "not exactly one link in confirmation page" | ||
| oauth_uri = p.links[0] | ||
| return oauth_uri | ||
|
|
||
| def send_read_receipt(self, room_id: str, event_id: str, *, tok: str) -> None: | ||
| """Send a read receipt into the room at the given event""" | ||
| channel = make_request( | ||
| self.reactor, | ||
| self.site, | ||
| method="POST", | ||
| path=f"/rooms/{room_id}/receipt/{ReceiptTypes.READ}/{event_id}", | ||
| content={}, | ||
| access_token=tok, | ||
| ) | ||
| assert channel.code == HTTPStatus.OK, channel.text_body | ||
|
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Should we use this helper for the rest of the There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Yup, we should, just didn't want to inflate the PR |
||
Uh oh!
There was an error while loading. Please reload this page.