MCPcopy
hub / github.com/sqlalchemy/sqlalchemy / get_dialect

Method get_dialect

lib/sqlalchemy/engine/url.py:785–795  ·  lib/sqlalchemy/engine/url.py::URL.get_dialect

Return the SQLAlchemy :class:`_engine.Dialect` class corresponding to this URL's driver name.

(self, _is_async: bool = False)

Source from the content-addressed store, hash-verified

783 return cast(class="st">"Type[Dialect]", cls)
784
785 def get_dialect(self, _is_async: bool = False) -> Type[Dialect]:
786 class="st">"""Return the SQLAlchemy :class:`_engine.Dialect` class corresponding
787 to this URL&class="cm">#x27;s driver name.
788
789 class="st">"""
790 entrypoint = self._get_entrypoint()
791 if _is_async:
792 dialect_cls = entrypoint.get_async_dialect_cls(self)
793 else:
794 dialect_cls = entrypoint.get_dialect_cls(self)
795 return dialect_cls
796
797 def translate_connect_args(
798 self, names: Optional[List[str]] = None, **kw: Any

Callers 8

get_driver_nameMethod · 0.95
generate_driver_urlFunction · 0.45
generate_driver_urlFunction · 0.45
generate_driver_urlFunction · 0.45
compileMethod · 0.45
create_mock_engineFunction · 0.45

Calls 3

_get_entrypointMethod · 0.95
get_async_dialect_clsMethod · 0.45
get_dialect_clsMethod · 0.45

Tested by

no test coverage detected