diff options
author | Richard van der Hoff <1389908+richvdh@users.noreply.github.com> | 2021-05-24 14:02:01 +0100 |
---|---|---|
committer | GitHub <noreply@github.com> | 2021-05-24 14:02:01 +0100 |
commit | c0df6bae066fe818bb80d41af65503be7a07275d (patch) | |
tree | b12bade69c01d30d453c718fe70b9186890c4bc9 /synapse/util/caches/descriptors.py | |
parent | Enable experimental spaces by default. (#10011) (diff) | |
download | synapse-c0df6bae066fe818bb80d41af65503be7a07275d.tar.xz |
Remove `keylen` from `LruCache`. (#9993)
`keylen` seems to be a thing that is frequently incorrectly set, and we don't really need it. The only time it was used was to figure out if we had removed a subtree in `del_multi`, which we can do better by changing `TreeCache.pop` to return a different type (`TreeCacheNode`). Commits should be independently reviewable.
Diffstat (limited to 'synapse/util/caches/descriptors.py')
-rw-r--r-- | synapse/util/caches/descriptors.py | 1 |
1 files changed, 0 insertions, 1 deletions
diff --git a/synapse/util/caches/descriptors.py b/synapse/util/caches/descriptors.py index 3a4d027095..2ac24a2f25 100644 --- a/synapse/util/caches/descriptors.py +++ b/synapse/util/caches/descriptors.py @@ -270,7 +270,6 @@ class DeferredCacheDescriptor(_CacheDescriptorBase): cache = DeferredCache( name=self.orig.__name__, max_entries=self.max_entries, - keylen=self.num_args, tree=self.tree, iterable=self.iterable, ) # type: DeferredCache[CacheKey, Any] |