mirror of
https://github.com/element-hq/synapse.git
synced 2026-04-26 13:07:46 +00:00
Summary of what was done in this session: New test files ported (11 files, 101 tests): - test_typing.py (3 tests) - test_capabilities.py (12 tests) - test_events.py (7 tests) - test_ephemeral_message.py (2 tests) - test_presence.py (5 tests) - test_profile.py (25 tests) - test_directory.py (7 tests) - test_power_levels.py (7 tests) - test_read_marker.py (2 tests) - test_mutual_rooms.py (12 tests) - test_notifications.py (5 tests) Infrastructure fixes: - FutureCache tree invalidation: Implemented _invalidate_prefix() for tree=True caches — prefix-based key matching was silently broken. - NativeConnectionPool.running: Added missing property needed by DatabasePool.is_running(). - NativeClock.call_later fake time: call_later now stores callbacks in a pending heap when fake time is enabled, and advance() fires them. Previously, call_later used the real event loop timer which ignored fake time. - pump() enhanced: Now yields 20 × 0.01s (real time) after advancing fake time, giving background tasks and executor threads time to complete. - Logging context cleanup: setUp now resets to SENTINEL instead of failing, since asyncio event loop shutdown between tests can leave non-sentinel contexts. - SynapseRequest.finish() calls channel.requestDone(): Populates resource_usage on FakeChannel. - make_signed_federation_request made async: Added await to all call sites.