Code
Hub
Workspaces
Following
Trending
Connect
MCP
copy
Create free account
hub
/
github.com/MagicStack/asyncpg
/ is_connected
Method
is_connected
asyncpg/pool.py:159–160 ·
view source on GitHub ↗
(self)
Source
from the content-addressed store, hash-verified
157
self._generation: Optional[int] = None
158
159
def
is_connected(self) -> bool:
160
return
self._con is not None and not self._con.is_closed()
161
162
def
is_idle(self) -> bool:
163
return
not self._in_use
Callers
8
_deactivate_inactive_connection
Method · 0.95
test_pool_min_size_reuses_retained_connections
Method · 0.80
test_pool_min_size_restored_after_multiple_losses
Method · 0.80
is_closed
Method · 0.80
_get
Method · 0.80
get_disconnected_nowait
Method · 0.80
get_size
Method · 0.80
get_idle_size
Method · 0.80
Calls
1
is_closed
Method · 0.80
Tested by
2
test_pool_min_size_reuses_retained_connections
Method · 0.64
test_pool_min_size_restored_after_multiple_losses
Method · 0.64