mirror of https://github.com/apache/superset.git
fix: MySQL et al. super calls (#23971)
This commit is contained in:
parent
724fd82919
commit
2af76fc41f
|
@ -205,9 +205,13 @@ class MySQLEngineSpec(BaseEngineSpec, BasicParametersMixin):
|
||||||
catalog: Optional[str] = None,
|
catalog: Optional[str] = None,
|
||||||
schema: Optional[str] = None,
|
schema: Optional[str] = None,
|
||||||
) -> Tuple[URL, Dict[str, Any]]:
|
) -> Tuple[URL, Dict[str, Any]]:
|
||||||
uri, new_connect_args = super(
|
uri, new_connect_args = super().adjust_engine_params(
|
||||||
MySQLEngineSpec, MySQLEngineSpec
|
uri,
|
||||||
).adjust_engine_params(uri, connect_args, catalog, schema)
|
connect_args,
|
||||||
|
catalog,
|
||||||
|
schema,
|
||||||
|
)
|
||||||
|
|
||||||
if schema:
|
if schema:
|
||||||
uri = uri.set(database=parse.quote(schema, safe=""))
|
uri = uri.set(database=parse.quote(schema, safe=""))
|
||||||
|
|
||||||
|
|
|
@ -261,9 +261,7 @@ class OcientEngineSpec(BaseEngineSpec):
|
||||||
cls, cursor: Any, limit: Optional[int] = None
|
cls, cursor: Any, limit: Optional[int] = None
|
||||||
) -> List[Tuple[Any, ...]]:
|
) -> List[Tuple[Any, ...]]:
|
||||||
try:
|
try:
|
||||||
rows: List[Tuple[Any, ...]] = super(OcientEngineSpec, cls).fetch_data(
|
rows: List[Tuple[Any, ...]] = super().fetch_data(cursor, limit)
|
||||||
cursor, limit
|
|
||||||
)
|
|
||||||
except Exception as exception:
|
except Exception as exception:
|
||||||
with OcientEngineSpec.query_id_mapping_lock:
|
with OcientEngineSpec.query_id_mapping_lock:
|
||||||
del OcientEngineSpec.query_id_mapping[
|
del OcientEngineSpec.query_id_mapping[
|
||||||
|
|
Loading…
Reference in New Issue