chore(backend): standardize multiline formatting across modules

Reformatted multiline function calls, object definitions, and queries for improved code readability and consistency. Adjusted imports and constraints where necessary.
This commit is contained in:
2026-01-03 01:35:18 +01:00
parent da5affd613
commit acd18ff694
26 changed files with 540 additions and 357 deletions

View File

@@ -243,7 +243,9 @@ class RedisClient:
try:
client = await self._get_client()
result = await client.expire(key, ttl)
logger.debug(f"Cache expire for key: {key} (TTL: {ttl}s, success: {result})")
logger.debug(
f"Cache expire for key: {key} (TTL: {ttl}s, success: {result})"
)
return result
except (ConnectionError, TimeoutError) as e:
logger.error(f"Redis cache_expire failed for key '{key}': {e}")
@@ -323,9 +325,7 @@ class RedisClient:
return 0
@asynccontextmanager
async def subscribe(
self, *channels: str
) -> AsyncGenerator[PubSub, None]:
async def subscribe(self, *channels: str) -> AsyncGenerator[PubSub, None]:
"""
Subscribe to one or more channels.
@@ -353,9 +353,7 @@ class RedisClient:
logger.debug(f"Unsubscribed from channels: {channels}")
@asynccontextmanager
async def psubscribe(
self, *patterns: str
) -> AsyncGenerator[PubSub, None]:
async def psubscribe(self, *patterns: str) -> AsyncGenerator[PubSub, None]:
"""
Subscribe to channels matching patterns.