MCPcopy Create free account
hub / github.com/sqlalchemy/sqlalchemy / _cleanup

Method _cleanup

lib/sqlalchemy/pool/impl.py:410–413  ·  view source on GitHub ↗
(self)

Source from the content-addressed store, hash-verified

408 self._all_conns.clear()
409
410 def _cleanup(self) -> None:
411 while len(self._all_conns) >= self.size:
412 c = self._all_conns.pop()
413 c.close()
414
415 def status(self) -> str:
416 return "SingletonThreadPool id:%d size: %d" % (

Callers 1

_do_getMethod · 0.95

Calls 2

popMethod · 0.45
closeMethod · 0.45

Tested by

no test coverage detected