mirror of
https://code.lenaisten.de/Lenaisten/advent22.git
synced 2024-11-23 08:13:01 +00:00
hack handle key miss
This commit is contained in:
parent
4415c0f861
commit
02cb654022
1 changed files with 8 additions and 2 deletions
|
@ -71,8 +71,14 @@ class WebDAV:
|
||||||
|
|
||||||
cls._webdav_client.resource(path).read_from(buffer)
|
cls._webdav_client.resource(path).read_from(buffer)
|
||||||
|
|
||||||
# Cache-Eintrag entfernen (hack: siehe AsyncTTL._TTL.__contains__)
|
try:
|
||||||
del cls._rb_ttl.ttl[KEY((path,), {})]
|
# hack: zugehörigen Cache-Eintrag entfernen
|
||||||
|
# -> AsyncTTL._TTL.__contains__
|
||||||
|
del cls._rb_ttl.ttl[KEY((path,), {})]
|
||||||
|
|
||||||
|
except KeyError:
|
||||||
|
# Cache-Eintrag existierte nicht
|
||||||
|
pass
|
||||||
|
|
||||||
@classmethod
|
@classmethod
|
||||||
async def write_str(cls, path: str, content: str, encoding="utf-8") -> None:
|
async def write_str(cls, path: str, content: str, encoding="utf-8") -> None:
|
||||||
|
|
Loading…
Reference in a new issue