We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent f72abbf commit b0c78edCopy full SHA for b0c78ed
sqlalchemy-stubs/pool/base.pyi
@@ -32,10 +32,10 @@ class Pool(log.Identified):
32
pre_ping: bool = ...,
33
_dispatch: Optional[Any] = ...,
34
) -> None: ...
35
- def recreate(self) -> None: ...
+ def recreate(self) -> Pool: ...
36
def dispose(self) -> None: ...
37
def connect(self): ...
38
- def status(self) -> None: ...
+ def status(self) -> str: ...
39
40
class _ConnectionRecord:
41
finalize_callback: Any = ...
test/files/pool_recreate_status.py
@@ -0,0 +1,5 @@
1
+import sqlalchemy, sqlalchemy.pool
2
+
3
+engine = sqlalchemy.create_engine("postgresql://scott:tiger@localhost/test")
4
+status: str = engine.pool.status()
5
+other_pool: sqlalchemy.pool.Pool = engine.pool.recreate()
0 commit comments