mirror of
https://mau.dev/maunium/synapse.git
synced 2024-11-16 06:51:46 +01:00
7ff22d6da4
When all entries in an `LruCache` have a size of 0 according to the provided `size_callback`, and `drop_from_cache` is called on a cache node, the node would be unlinked from the LRU linked list but remain in the cache dictionary. An assertion would be later be tripped due to the inconsistency. Avoid unintentionally calling `__len__` and use a strict `is None` check instead when unwrapping the weak reference. |
||
---|---|---|
.. | ||
caches | ||
__init__.py | ||
test_async_helpers.py | ||
test_batching_queue.py | ||
test_dict_cache.py | ||
test_expiring_cache.py | ||
test_file_consumer.py | ||
test_glob_to_regex.py | ||
test_itertools.py | ||
test_linearizer.py | ||
test_logcontext.py | ||
test_logformatter.py | ||
test_lrucache.py | ||
test_ratelimitutils.py | ||
test_retryutils.py | ||
test_rwlock.py | ||
test_stream_change_cache.py | ||
test_stringutils.py | ||
test_threepids.py | ||
test_treecache.py | ||
test_wheel_timer.py |