-
Notifications
You must be signed in to change notification settings - Fork 224
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
Add rooms.required_state
to Sliding Sync /sync
#17342
Merged
MadLittleMods
merged 123 commits into
develop
from
madlittlemods/sliding-sync-required-state
Jul 4, 2024
Merged
Changes from all commits
Commits
Show all changes
123 commits
Select commit
Hold shift + click to select a range
079194c
Return some room timeline data in Sliding Sync
MadLittleMods 3e0f759
Strip invite/knock event itself and avoid mutating event `unsigned`
MadLittleMods 5e2fd4e
Add changelog
MadLittleMods 8ce06f1
Fix sort being lost
MadLittleMods aa5f54a
Start on required_state
MadLittleMods 5c175d5
Add some notes from pairing
MadLittleMods 9089bfe
Remove required_state for now
MadLittleMods 9427991
Clean up knock_state comments
MadLittleMods 19b2297
Calculate `num_live`
MadLittleMods 81d36f3
Add tests for `limited`
MadLittleMods 9791209
Add more tests
MadLittleMods 70ecd4d
Fix lint
MadLittleMods 71eabe5
Make room name optional
MadLittleMods 39b4f10
Update comments
MadLittleMods 9883b0f
Add bundled aggregations
MadLittleMods 1c06153
Determine limited before filtering
MadLittleMods 57ba033
Merge branch 'develop' into madlittlemods/sliding-sync-room-data
MadLittleMods c81f300
Add better support for leave/ban
MadLittleMods d801db0
Fix lints
MadLittleMods 6942b64
Merge branch 'develop' into madlittlemods/sliding-sync-room-data
MadLittleMods 884b448
Update some wording
MadLittleMods ef3f606
Start of combinining `RoomSyncConfig`
MadLittleMods bbc3eb5
Different better
MadLittleMods 0eb0294
Remove unused `IncludeOldRooms` class
MadLittleMods 5b17d70
Add `RoomSyncConfig` tests
MadLittleMods b6edd6b
Better `RoomSyncConfig` tests
MadLittleMods cddcf1f
Fetch required state
MadLittleMods ddbcd78
Add future note about other people we might care about when lazy-load…
MadLittleMods 55ad559
Start of thinking to handle partial stated rooms
MadLittleMods 41988a7
Allow the next room to fill its place if we exclude a partially-state…
MadLittleMods 8dc4009
Add a test
MadLittleMods 5fdbeff
Make sure we add some specific tests
MadLittleMods b1b4231
Merge branch 'develop' into madlittlemods/sliding-sync-room-data
MadLittleMods 87fac19
Fix lints
MadLittleMods 0e71a2f
Add TODO for filtering call invites in public rooms
MadLittleMods 21ca02c
`newly_joined` vs `limited` already being tracked in a discussion
MadLittleMods 3568311
Fix spelling typo
MadLittleMods 7aea406
Just stripped_state for invite rooms
MadLittleMods e3e431f
Finish up stripped_state for invite rooms
MadLittleMods 303d834
Add tracking discussion for not optional in the future
MadLittleMods 4c22131
Start testing for the correct room membership (failing)
MadLittleMods 83d6f76
Describe `current_state_delta_stream` better
MadLittleMods fbd92e1
Add `get_current_state_delta_membership_changes_for_user(...)` (using…
MadLittleMods 6c791a8
WIP: Add back `newly_left`
MadLittleMods 27d74b0
Iterate
MadLittleMods fb8fbd4
Just fetch full events for `get_current_state_delta_membership_change…
MadLittleMods d91aa00
Remove extras
MadLittleMods daa7e36
Add docstring
MadLittleMods cccbd15
Refactor back to not pulling out full events
MadLittleMods 62c6a4e
Add `newly_joined` support to `get_sync_room_ids_for_user(...)`
MadLittleMods 39259f6
Join both tables with stream_ordering
MadLittleMods 5c21315
Merge branch 'develop' into madlittlemods/sliding-sync-room-data
MadLittleMods c60aca7
Fix clause change
MadLittleMods 11db1be
Remove debug log
MadLittleMods 7395e10
Fix `builtins.SyntaxError: EOL while scanning string literal (test_sy…
MadLittleMods 2bf3923
Add some tests for `get_current_state_delta_membership_changes_for_us…
MadLittleMods ec2d8dc
Create events using helper
MadLittleMods 0b9a903
Add test that remotely joins room
MadLittleMods 48d0acf
Actually test `get_current_state_delta_membership_changes_for_user(..…
MadLittleMods 2a944ff
Add state of the db in each situation
MadLittleMods 8df39d1
Remove redundant `instance_name` column
MadLittleMods b7914e7
Add skipped test for state resets
MadLittleMods 7eb1806
Fix lints
MadLittleMods 935b98c
All `get_current_state_delta_membership_changes_for_user(...)` tests …
MadLittleMods f163fcf
Remove need for topological_ordering
MadLittleMods 956f20e
(currently failing) Add test to make sure membership changes don't re…
MadLittleMods 830e09d
Grab `prev_membership` to see whether the server left the room (fixes…
MadLittleMods 15fcead
Slight clean-up
MadLittleMods 81c06be
Detect state resets
MadLittleMods eb159c1
Don't worry about `state_reset` for now
MadLittleMods ba56350
Passing current tests
MadLittleMods f774032
Add better comments
MadLittleMods 325856e
Inclusive ranges
MadLittleMods 63c7b50
(doesn't work) Add test for batch persisting multiple member events f…
MadLittleMods 1158058
Opt for tackling more batch scenarios in future PRs
MadLittleMods 32b8b68
Add TODO to handle state resets
MadLittleMods 6045e11
Merge branch 'develop' into madlittlemods/sliding-sync-room-data
MadLittleMods 9e53336
Avoid fetching full events for `prev_event_ids`
MadLittleMods a4263bf
Update stream tests with prev event info
MadLittleMods 10d78d6
Protect for non-existent prev events
MadLittleMods 0061561
Merge branch 'develop' into madlittlemods/sliding-sync-room-data
MadLittleMods 73f2903
Merge branch 'madlittlemods/sliding-sync-room-data' into madlittlemod…
MadLittleMods e419587
Protect from no timeline_events
MadLittleMods 2bd6cba
Select `to_key if to_key else from_key`
MadLittleMods b8687e7
Select `to_key if to_key else from_key`
MadLittleMods 7c9513c
Add missing test description
MadLittleMods dfb4324
Merge branch 'madlittlemods/sliding-sync-room-data' into madlittlemod…
MadLittleMods 78df54a
Get state at leave/ban
MadLittleMods 8b73185
Trigger CI again
MadLittleMods 8aa2297
Merge branch 'madlittlemods/sliding-sync-room-data' into madlittlemod…
MadLittleMods 939b9ce
room_state can be None
MadLittleMods 126ce1e
Merge branch 'develop' into madlittlemods/sliding-sync-room-data
erikjohnston cae489b
Merge branch 'madlittlemods/sliding-sync-room-data' into madlittlemod…
MadLittleMods 2175edf
Merge branch 'develop' into madlittlemods/sliding-sync-required-state
MadLittleMods 01a4b43
Rename `get_state_at` -> `get_state_ids_at`
MadLittleMods 77b8d9c
Add `get_state_at(...)` that returns full events
MadLittleMods a3ac718
Some clean-up
MadLittleMods c935d03
Merge branch 'develop' into madlittlemods/sliding-sync-required-state
MadLittleMods c71cf86
Handle wildcard merges in from_config
MadLittleMods dcad14b
Support multiple wildcard types
MadLittleMods ce503fc
Parameterize tests
MadLittleMods 4eb82e3
Combine wildcard configs
MadLittleMods 646b328
No need for `get_first_item_in_set(...)`
MadLittleMods f2e0c5e
Workaround wildcard event types
MadLittleMods 859f9b0
Rename to `StateValues` because it can be used in the event_type or s…
MadLittleMods 2c4eea7
Add `_assertIncludes(...)` and `_assertRequiredStateIncludes(...)`
MadLittleMods c1222c6
Add exact option
MadLittleMods 75446e7
Add more tests
MadLittleMods aa59ead
Fix lints
MadLittleMods cc30a85
Add changelog
MadLittleMods 5c8dd69
Either or
MadLittleMods ea78da5
Add explicit test for no required_state
MadLittleMods 5023943
Bette as a fixme
MadLittleMods fbad6b0
Fix `\n` backslash usage forbidden in f-string
MadLittleMods b3ca35e
Hoist repetitive logic outside loop
MadLittleMods dc8bef0
Remove extra safety check
MadLittleMods f2174c1
Move comment to the right place
MadLittleMods e22a291
Refactor to map from event type to list of state keys
MadLittleMods fe4f2ea
Refactor usage
MadLittleMods 52444d9
Better loop pattern
MadLittleMods 7c133a8
Fix lint
MadLittleMods 3cf9a77
Add line break between if-cases
MadLittleMods 7ef822c
Merge branch 'develop' into madlittlemods/sliding-sync-required-state
MadLittleMods File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
Return "required state" in experimental [MSC3575](https://github.com/matrix-org/matrix-spec-proposals/pull/3575) Sliding Sync `/sync` endpoint. |
Large diffs are not rendered by default.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Renamed
get_state_at(...)
->get_state_ids_at(...)
to be accurateAlso add
get_state_at(...)
since we have a use now