frontend groundwork
Some checks failed
Build and release APK / Build APK (pull_request) Has been cancelled
Build and push docker image / Build (pull_request) Successful in 1m33s

This commit is contained in:
2024-08-01 14:39:15 +02:00
parent 07dde5ab58
commit 86bcec6b29
16 changed files with 417 additions and 168 deletions

View File

@@ -8,11 +8,19 @@ class DummyClient:
def set(self, key, value, **kwargs):
self._data[key] = value
def set_many(self, data, **kwargs):
self._data.update(data)
def get(self, key, **kwargs):
return self._data[key]
if constants.MEMCACHE_HOST is None:
if constants.MEMCACHED_HOST_PATH is None:
client = DummyClient()
else:
client = Client(constants.MEMCACHE_HOST, timeout=1)
client = Client(
constants.MEMCACHED_HOST_PATH,
timeout=1,
allow_unicode_keys=True,
encoding='utf-8'
)