1
0
Fork 0
mirror of https://github.com/element-hq/synapse.git synced 2025-03-06 16:06:52 +00:00
synapse/tests
Mathieu Velten b3ba501c52
Properly purge state groups tables when purging a room (#18024)
Currently purging a complex room can lead to a lot of orphaned rows left
behind in the state groups tables.
It seems it is because we are loosing track of state groups sometimes.

This change uses the `room_id` indexed column of `state_groups` table to
decide what to delete instead of doing an indirection through
`event_to_state_groups`.

Related to https://github.com/element-hq/synapse/issues/3364.

### Pull Request Checklist

* [x] Pull request is based on the develop branch
* [x] Pull request includes a [changelog
file](https://element-hq.github.io/synapse/latest/development/contributing_guide.html#changelog).
* [x] [Code
style](https://element-hq.github.io/synapse/latest/code_style.html) is
correct
(run the
[linters](https://element-hq.github.io/synapse/latest/development/contributing_guide.html#run-the-linters))

---------

Co-authored-by: Erik Johnston <erikj@jki.re>
2025-01-06 15:32:18 +00:00
..
api Consolidate SSO redirects through /_matrix/client/v3/login/sso/redirect(/{idpId}) (#17972) 2024-11-29 11:26:37 -06:00
app Correctly mention previous copyright (#16820) 2024-01-23 11:26:48 +00:00
appservice Format files with Ruff (#17643) 2024-09-02 12:39:04 +01:00
config Add macaroon_secret_key_path config option (#17983) 2024-12-16 18:01:33 -06:00
crypto Correctly mention previous copyright (#16820) 2024-01-23 11:26:48 +00:00
events Format files with Ruff (#17643) 2024-09-02 12:39:04 +01:00
federation Fix up logic for delaying sending read receipts over federation. (#17933) 2024-11-25 18:12:33 +00:00
handlers Add email.tlsname config option (#17849) 2024-12-17 18:05:38 -06:00
http Fix mypy errors on Twisted 24.11.0 (#17998) 2024-12-18 11:49:38 +00:00
logging Removal: Remove support for experimental msc3886 (#17638) 2024-11-13 14:10:20 +00:00
media Enable authenticated media by default (#17889) 2024-11-20 14:48:22 +00:00
metrics Correctly mention previous copyright (#16820) 2024-01-23 11:26:48 +00:00
module_api Format files with Ruff (#17643) 2024-09-02 12:39:04 +01:00
push MSC4076: Add disable_badge_count to pusher configuration (#17975) 2024-12-03 22:58:43 +00:00
replication Bump mypy from 1.11.2 to 1.12.1 and fix new typechecking errors (#17999) 2024-12-18 11:42:17 +00:00
rest Properly purge state groups tables when purging a room (#18024) 2025-01-06 15:32:18 +00:00
scripts Update license headers 2023-11-21 15:29:58 -05:00
server_notices Sliding Sync: Add cache to get_tags_for_room(...) (#17730) 2024-09-19 12:43:26 +01:00
state Update license headers 2023-11-21 15:29:58 -05:00
storage Remove support for python 3.8 (#17908) 2024-11-06 19:36:01 +00:00
test_utils Add media tests for a CMYK JPEG image (#17786) 2024-10-23 18:26:01 +01:00
types Use immutabledict instead of frozendict (#15113) 2023-03-22 17:15:34 +00:00
util Fix new scheduled tasks jumping the queue (#17962) 2024-11-28 18:06:19 +00:00
__init__.py Correctly mention previous copyright (#16820) 2024-01-23 11:26:48 +00:00
server.py Removal: Remove support for experimental msc3886 (#17638) 2024-11-13 14:10:20 +00:00
test_distributor.py Correctly mention previous copyright (#16820) 2024-01-23 11:26:48 +00:00
test_event_auth.py Format files with Ruff (#17643) 2024-09-02 12:39:04 +01:00
test_federation.py Format files with Ruff (#17643) 2024-09-02 12:39:04 +01:00
test_mau.py Update license headers 2023-11-21 15:29:58 -05:00
test_phone_home.py Correctly mention previous copyright (#16820) 2024-01-23 11:26:48 +00:00
test_rust.py Add missing type hints to tests. (#15027) 2023-02-08 19:52:37 +00:00
test_server.py Removal: Remove support for experimental msc3886 (#17638) 2024-11-13 14:10:20 +00:00
test_state.py Correctly mention previous copyright (#16820) 2024-01-23 11:26:48 +00:00
test_terms_auth.py Update license headers 2023-11-21 15:29:58 -05:00
test_test_utils.py Correctly mention previous copyright (#16820) 2024-01-23 11:26:48 +00:00
test_types.py Format files with Ruff (#17643) 2024-09-02 12:39:04 +01:00
test_visibility.py Include user membership on events (#17282) 2024-06-13 21:45:54 +00:00
unittest.py Support for MSC4190: device management for application services (#17705) 2024-12-04 12:04:49 +01:00
utils.py Improve lock performance when a lot of locks are waiting (#16840) 2024-03-14 13:49:54 +00:00