"""
if kwargs:
raise TypeError(f"keyword not supported: {list(kwargs)[0]}")
- with self._conn.lock:
- self._conn.wait(
- self._helper._declare_gen(self, query, params, binary)
- )
+
+ try:
+ with self._conn.lock:
+ self._conn.wait(
+ self._helper._declare_gen(self, query, params, binary)
+ )
+ except e.Error as ex:
+ raise ex.with_traceback(None)
return self
) -> _AC:
if kwargs:
raise TypeError(f"keyword not supported: {list(kwargs)[0]}")
- async with self._conn.lock:
- await self._conn.wait(
- self._helper._declare_gen(self, query, params, binary)
- )
+ try:
+ async with self._conn.lock:
+ await self._conn.wait(
+ self._helper._declare_gen(self, query, params, binary)
+ )
+ except e.Error as ex:
+ raise ex.with_traceback(None)
return self