summary refs log tree commit diff
path: root/synapse/handlers/room_summary.py (follow)
Commit message (Collapse)AuthorAgeFilesLines
* Correctly mention previous copyright (#16820)Erik Johnston2024-01-231-0/+1
| | | | | During the migration the automated script to update the copyright headers accidentally got rid of some of the existing copyright lines. Reinstate them.
* Reduce amount of state pulled out when querying federation hierachy (#16785)Erik Johnston2024-01-101-1/+11
| | | | | | | | | | | There are two changes here: 1. Only pull out the required state when handling the request. 2. Change the get filtered state return type to check that we're only querying state that was requested --------- Co-authored-by: reivilibre <oliverw@matrix.org>
* Update license headersPatrick Cloke2023-11-211-10/+16
|
* Remove remaining usage of cursor_to_dict. (#16564)Patrick Cloke2023-10-311-13/+13
|
* Describe which rate limiter was hit in logs (#16135)David Robertson2023-08-301-1/+4
|
* Support room version 11 (#15912)Patrick Cloke2023-07-181-2/+2
| | | | | And fix a bug in the implementation of the updated redaction format (MSC2174) where the top-level redacts field was not properly added for backwards-compatibility.
* Tweak comment on `_is_local_room_accessible` as part of room visibility in ↵reivilibre2023-02-131-2/+2
| | | | `/hierarchy` to clarify the condition for a room being visible. (#14834)
* Use StrCollection in place of Collection[str] in (most) handlers code. (#14922)Patrick Cloke2023-01-261-2/+2
| | | | Due to the increased safety of StrCollection over Collection[str] and Sequence[str].
* Use the room type from stats in hierarchy response. (#14263)Patrick Cloke2022-12-131-9/+5
| | | | | | | | | This avoids pulling additional state information (and events) from the database for each item returned in the hierarchy response. The room type might be out of date until a background update finishes running, the worst impact of this would be spaces being treated as rooms in the hierarchy response. This should self-heal once the background update finishes.
* Faster Remote Room Joins: tell remote homeservers that we are unable to ↵reivilibre2022-09-231-4/+2
| | | | authorise them if they query a room which has partial state on our server. (#13823)
* Remove the unspecced room_id field in the /hierarchy response. (#13506)reivilibre2022-09-061-1/+0
| | | | | | | | | | | This is a re-do of 57d334a13d983406ea452dfa203bbe4837509c4e (#13365), which was backed out in 12abd724974a2311d5311272d26d2f8aa11734a9 (#13501). The `room_id` field represented the parent space for each room and was made redundant by changes in the API shape where the `children_state` is now nested underneath each `room`. The room ID of each child is in the `state_key` field and is still available.
* Revert 'Remove the unspecced field in the response. (#13365)' to give more ↵reivilibre2022-08-111-0/+1
| | | | time for clients to update. (#13501)
* Implement MSC3848: Introduce errcodes for specific event sending failures ↵Will Hunt2022-07-271-2/+3
| | | | | (#13343) Implements MSC3848
* Remove the unspecced `room_id` field in the `/hierarchy` response. (#13365)Patrick Cloke2022-07-261-1/+0
| | | | | | | | | The `room_id` field represented the parent space for each room and was made redundant by changes in the API shape where the `children_state` is now nested underneath each `room`. The room ID of each child is in the `state_key` field and is still available.
* Wait for lazy join to complete when getting current state (#12872)Erik Johnston2022-06-011-3/+8
|
* Remove unstable APIs for /hierarchy. (#12851)Patrick Cloke2022-05-261-4/+1
| | | | Removes the unstable endpoint as well as a duplicated field which was modified during stabilization.
* Fixes to MSC3787 implementation (#12858)David Robertson2022-05-241-1/+2
|
* Add a new room version for MSC3787's knock+restricted join rule (#12623)Travis Ralston2022-05-171-2/+7
|
* Support MSC3266 room summaries over federation (#11507)DeepBlueV7.X2022-05-051-5/+49
| | | | Signed-off-by: Nicolas Werner <nicolas.werner@hotmail.de>
* Do not return allowed_room_ids from /hierarchy response. (#12175)Patrick Cloke2022-03-081-2/+13
| | | | | This field is only to be used in the Server-Server API, and not the Client-Server API, but was being leaked when a federation response was used in the /hierarchy API.
* Check if instances are lists, not sequences. (#12128)Patrick Cloke2022-03-021-1/+1
| | | | | As a str is a sequence, the checks were not granular enough and would allow lists or strings, when only lists were valid.
* Remove the unstable `/spaces` endpoint. (#12073)Patrick Cloke2022-02-281-312/+11
| | | | | | | | ...and various code supporting it. The /spaces endpoint was from an old version of MSC2946 and included both a Client-Server and Server-Server API. Note that the unstable /hierarchy endpoint (from the final version of MSC2946) is not yet removed.
* Remove `HomeServer.get_datastore()` (#12031)Richard van der Hoff2022-02-231-1/+1
| | | | | | | The presence of this method was confusing, and mostly present for backwards compatibility. Let's get rid of it. Part of #11733
* Fix a bug that corrupted the cache of federated space hierarchies (#11775)Sean Quah2022-01-201-1/+2
| | | | `FederationClient.get_room_hierarchy()` caches its return values, so refactor the code to avoid modifying the returned room summary.
* Support spaces with > 50 rooms in the /hierarchy endpoint. (#11695)Patrick Cloke2022-01-071-8/+22
| | | | | | | By returning all of the m.space.child state of the space, not just the first 50. The number of rooms returned is still capped at 50. For the federation API this implies that the requesting server will need to individually query for any other rooms it is not joined to.
* Fix space hierarchy endpoint to match MSC2946 (#11667)Travis Ralston2022-01-051-2/+4
| | | | | | | Fixes minor discrepancies between the /hierarchy endpoint described in MSC2946 and the implementation. Note that the changes impact the stable and unstable /hierarchy and unstable /spaces endpoints for both client and federation APIs.
* Support the stable /hierarchy endpoint from MSC2946 (#11329)Patrick Cloke2021-11-291-4/+10
| | | | | | This also makes additional updates where the implementation had drifted from the approved MSC. Unstable endpoints will be removed at a later data.
* Avoid sharing room hierarchy responses between users (#11355)Sean Quah2021-11-161-2/+9
| | | | | Different users may be allowed to see different rooms within a space, so sharing responses between users is inadvisable.
* Remove unnecessary parentheses around tuples returned from methods (#10889)Andrew Morgan2021-09-231-1/+1
|
* Require type hints in the handlers module. (#10831)Patrick Cloke2021-09-201-1/+1
| | | | | | | Adds missing type hints to methods in the synapse.handlers module and requires all methods to have type hints there. This also removes the unused construct_auth_difference method from the FederationHandler.
* Return stripped m.space.child events via the space summary. (#10760)Patrick Cloke2021-09-071-14/+12
| | | | | | | | | The full event content cannot be trusted from this API (as no auth chain, etc.) is processed over federation. Returning the full event content was a bug as MSC2946 specifies that only the stripped state should be returned. This also avoids calculating aggregations / annotations which go unused.
* Ignore rooms with unknown room versions in the spaces summary. (#10727)Patrick Cloke2021-09-011-2/+14
| | | | This avoids breaking the entire endpoint if a room with an unsupported room version is encountered.
* Consider the `origin_server_ts` of the `m.space.child` event when ordering ↵Patrick Cloke2021-09-011-7/+8
| | | | | | | | | rooms. (#10730) This updates the ordering of the returned events from the spaces summary API to that defined in MSC2946 (which updates MSC1772). Previously a step was skipped causing ordering to be inconsistent with clients.
* Persist room hierarchy pagination sessions to the database. (#10613)Patrick Cloke2021-08-241-38/+38
|
* Experimental support for MSC3266 Room Summary API. (#10394)Michael Telatynski2021-08-161-0/+1171