Add pydocstyle to the ruff rules (#52136)

Signed-off-by: Harry Mellor <19981378+hmellor@users.noreply.github.com>
Signed-off-by: Harry Mellor <hej.mellor@gmail.com>
Co-authored-by: Claude Opus 5 (1M context) <noreply@anthropic.com>
This commit is contained in:
Harry Mellor
2026-09-16 16:44:29 +00:00
committed by GitHub
co-authored by Claude Opus 5
parent 804e5377aa
commit 8c1557a79c
2002 changed files with 15024 additions and 14269 deletions
+4 -6
View File
@@ -102,8 +102,7 @@ class LRUCache(cachetools.LRUCache[_K, _V]):
return self.currsize / self.maxsize
def stat(self, *, delta: bool = False) -> CacheInfo:
"""
Gets the cumulative number of hits and queries against this cache.
"""Gets the cumulative number of hits and queries against this cache.
If `delta=True`, instead gets these statistics
since the last call that also passed `delta=True`.
@@ -165,6 +164,7 @@ class LRUCache(cachetools.LRUCache[_K, _V]):
Returns:
`True` if the item was cached, otherwise `False`.
"""
try:
self[key] = value
@@ -175,8 +175,7 @@ class LRUCache(cachetools.LRUCache[_K, _V]):
return True
def pin(self, key: _K) -> None:
"""
Pins a key in the cache preventing it from being
"""Pins a key in the cache preventing it from being
evicted in the LRU order.
"""
if key not in self:
@@ -184,8 +183,7 @@ class LRUCache(cachetools.LRUCache[_K, _V]):
self.pinned_items.add(key)
def _unpin(self, key: _K) -> None:
"""
Unpins a key in the cache allowing it to be
"""Unpins a key in the cache allowing it to be
evicted in the LRU order.
"""
self.pinned_items.remove(key)