docs: add __aenter__/__aexit__ one-liner docstrings for twin parity with redis

Signed-off-by: disqualifier <dev@disqualifier.me>
This commit is contained in:
2026-07-06 02:55:58 -04:00
parent e4c61cf6c3
commit 71993fea1b
+2
View File
@@ -164,9 +164,11 @@ class PsqlDB:
self._pool = None self._pool = None
async def __aenter__(self) -> "PsqlDB": async def __aenter__(self) -> "PsqlDB":
"""enter: connect() and return self"""
return await self.connect() return await self.connect()
async def __aexit__(self, exc_type, exc, tb) -> None: async def __aexit__(self, exc_type, exc, tb) -> None:
"""exit: close(), ignoring exc_type/exc/tb"""
await self.close() await self.close()
@property @property