MCPcopy
hub / github.com/sqlalchemy/sqlalchemy / initialize

Method initialize

lib/sqlalchemy/engine/interfaces.py:1340–1356  ·  view source on GitHub ↗

Called during strategized creation of the dialect with a connection. Allows dialects to configure options based on server version info or other properties. The connection passed here is a SQLAlchemy Connection object, with full capabilities. The ini

(self, connection: Connection)

Source from the content-addressed store, hash-verified

1338 raise NotImplementedError()
1339
1340 def initialize(self, connection: Connection) -> None:
1341 """Called during strategized creation of the dialect with a
1342 connection.
1343
1344 Allows dialects to configure options based on server version info or
1345 other properties.
1346
1347 The connection passed here is a SQLAlchemy Connection object,
1348 with full capabilities.
1349
1350 The initialize() method of the base dialect should be called via
1351 super().
1352
1353 .. note:: as of SQLAlchemy 1.4, this method is called **before**
1354 any :meth:`_engine.Dialect.on_connect` hooks are called.
1355
1356 """
1357
1358 if TYPE_CHECKING:
1359

Callers 1

first_connectFunction · 0.45

Calls

no outgoing calls

Tested by

no test coverage detected