Skip to content

Commit 077a71c

Browse files
fix types
Signed-off-by: varun-edachali-dbx <varun.edachali@databricks.com>
1 parent b2d1579 commit 077a71c

File tree

3 files changed

+8
-8
lines changed

3 files changed

+8
-8
lines changed

src/databricks/sql/backend/databricks_client.py

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -3,6 +3,8 @@
33
from abc import ABC, abstractmethod
44
from typing import Dict, List, Optional, Any, Union, TYPE_CHECKING
55

6+
from databricks.sql.types import SSLOptions
7+
68
if TYPE_CHECKING:
79
from databricks.sql.client import Cursor
810
from databricks.sql.result_set import ResultSet
@@ -89,6 +91,7 @@ def execute_command(
8991
parameters: List[ttypes.TSparkParameter],
9092
async_op: bool,
9193
enforce_embedded_schema_correctness: bool,
94+
row_limit: Optional[int] = None,
9295
) -> Union[ResultSet, None]:
9396
"""
9497
Executes a SQL command or query within the specified session.

src/databricks/sql/backend/sea/backend.py

Lines changed: 5 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -14,6 +14,7 @@
1414
WaitTimeout,
1515
MetadataCommands,
1616
)
17+
from databricks.sql.thrift_api.TCLIService import ttypes
1718

1819
if TYPE_CHECKING:
1920
from databricks.sql.client import Cursor
@@ -404,7 +405,7 @@ def execute_command(
404405
lz4_compression: bool,
405406
cursor: Cursor,
406407
use_cloud_fetch: bool,
407-
parameters: List[Dict[str, Any]],
408+
parameters: List[ttypes.TSparkParameter],
408409
async_op: bool,
409410
enforce_embedded_schema_correctness: bool,
410411
row_limit: Optional[int] = None,
@@ -439,9 +440,9 @@ def execute_command(
439440
for param in parameters:
440441
sea_parameters.append(
441442
StatementParameter(
442-
name=param["name"],
443-
value=param["value"],
444-
type=param["type"] if "type" in param else None,
443+
name=param.name,
444+
value=param.value,
445+
type=param.type,
445446
)
446447
)
447448

src/databricks/sql/backend/thrift_backend.py

Lines changed: 0 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -235,10 +235,6 @@ def __init__(
235235
def max_download_threads(self) -> int:
236236
return self._max_download_threads
237237

238-
@property
239-
def max_download_threads(self) -> int:
240-
return self._max_download_threads
241-
242238
# TODO: Move this bounding logic into DatabricksRetryPolicy for v3 (PECO-918)
243239
def _initialize_retry_args(self, kwargs):
244240
# Configure retries & timing: use user-settings or defaults, and bound

0 commit comments

Comments
 (0)