sqlalchemy_singlestoredb.base.SingleStoreDBDialect.create_connect_args¶
- SingleStoreDBDialect.create_connect_args(url: URL) List[Any] ¶
Build DB-API compatible connection arguments.
Given a
URL
object, returns a tuple consisting of a(*args, **kwargs)
suitable to send directly to the dbapi’s connect function. The arguments are sent to theDialect.connect()
method which then runs the DBAPI-levelconnect()
function.The method typically makes use of the
URL.translate_connect_args()
method in order to generate a dictionary of options.The default implementation is:
def create_connect_args(self, url): opts = url.translate_connect_args() opts.update(url.query) return ([], opts)
- Parameters:
url – a
URL
object- Returns:
a tuple of
(*args, **kwargs)
which will be passed to theDialect.connect()
method.
See also
URL.translate_connect_args()