MCPcopy Create free account
hub / github.com/MagicStack/asyncpg / _unwrap

Method _unwrap

asyncpg/connection.py:1752–1761  ·  view source on GitHub ↗
(self)

Source from the content-addressed store, hash-verified

1750 self._loop.call_soon(cb.cb, con_ref, pid, channel, payload)
1751
1752 def _unwrap(self):
1753 if self._proxy is None:
1754 con_ref = self
1755 else:
1756 # `_proxy` is not None when the connection is a member
1757 # of a connection pool. Which means that the user is working
1758 # with a `PoolConnectionProxy` instance, and expects to see it
1759 # (and not the actual Connection) in their event callbacks.
1760 con_ref = self._proxy
1761 return con_ref
1762
1763 def get_reset_query(self):
1764 """Return the query sent to server on connection release.

Callers 3

_process_log_messageMethod · 0.95
_process_notificationMethod · 0.95

Calls

no outgoing calls

Tested by

no test coverage detected