synapse/tests/util
Eric Eastwood 0417296b9f
Remove logcontext problems caused by awaiting raw deferLater(...) (#19058)
This is a normal
problem where we `await` a deferred without wrapping it in
`make_deferred_yieldable(...)`. But I've opted to replace the usage of
`deferLater` with something more standard for the Synapse codebase.

Part of https://github.com/element-hq/synapse/issues/18905

It's unclear why we're only now seeing these failures happen with the
changes from https://github.com/element-hq/synapse/pull/19057

Example failures seen in
https://github.com/element-hq/synapse/actions/runs/18477454390/job/52645183606?pr=19057

```
builtins.AssertionError: Expected `looping_call` callback from the reactor to start with the sentinel logcontext but saw task-_resumable_task-0-IBzAmHUoepQfLnEA. In other words, another task shouldn't have leaked their logcontext to us.
```
2025-10-29 10:23:10 -05:00
..
caches Use type hinting generics in standard collections (#19046) 2025-10-22 16:48:19 -05:00
__init__.py Correctly mention previous copyright (#16820) 2024-01-23 11:26:48 +00:00
test_async_helpers.py Use type hinting generics in standard collections (#19046) 2025-10-22 16:48:19 -05:00
test_batching_queue.py Use type hinting generics in standard collections (#19046) 2025-10-22 16:48:19 -05:00
test_check_dependencies.py Remove support for python 3.8 (#17908) 2024-11-06 19:36:01 +00:00
test_dict_cache.py Cleanly shutdown SynapseHomeServer object (#18828) 2025-10-01 02:42:09 +00:00
test_events.py Add plain-text handling for rich-text topics as per MSC3765 (#18195) 2025-07-09 14:13:54 -05:00
test_expiring_cache.py Use type hinting generics in standard collections (#19046) 2025-10-22 16:48:19 -05:00
test_file_consumer.py Update license headers 2023-11-21 15:29:58 -05:00
test_itertools.py Use type hinting generics in standard collections (#19046) 2025-10-22 16:48:19 -05:00
test_linearizer.py Use type hinting generics in standard collections (#19046) 2025-10-22 16:48:19 -05:00
test_logcontext.py Cleanly shutdown SynapseHomeServer object (#18828) 2025-10-01 02:42:09 +00:00
test_logformatter.py Update license headers 2023-11-21 15:29:58 -05:00
test_lrucache.py Use type hinting generics in standard collections (#19046) 2025-10-22 16:48:19 -05:00
test_macaroons.py Correctly mention previous copyright (#16820) 2024-01-23 11:26:48 +00:00
test_mutable_overlay_mapping.py Use type hinting generics in standard collections (#19046) 2025-10-22 16:48:19 -05:00
test_ratelimitutils.py Refactor Counter metrics to be homeserver-scoped (#18656) 2025-07-25 14:58:47 -05:00
test_retryutils.py Cleanly shutdown SynapseHomeServer object (#18828) 2025-10-01 02:42:09 +00:00
test_rwlock.py Use type hinting generics in standard collections (#19046) 2025-10-22 16:48:19 -05:00
test_stream_change_cache.py Refactor cache metrics to be homeserver-scoped (#18604) 2025-07-16 16:04:57 -05:00
test_stringutils.py Implement MSC4133 to support custom profile fields. (#17488) 2025-01-21 11:11:04 +00:00
test_task_scheduler.py Remove logcontext problems caused by awaiting raw deferLater(...) (#19058) 2025-10-29 10:23:10 -05:00
test_threepids.py Correctly mention previous copyright (#16820) 2024-01-23 11:26:48 +00:00
test_treecache.py Correctly mention previous copyright (#16820) 2024-01-23 11:26:48 +00:00
test_wheel_timer.py Fix WheelTimer implementation that can expired timeout early (#17850) 2024-11-05 12:08:17 -06:00