Skip to content

Commit

Permalink
Merge branch 'master' into improve-pod
Browse files Browse the repository at this point in the history
  • Loading branch information
wild-endeavor authored Dec 21, 2022
2 parents 9b0f4e0 + 604e9a6 commit 7b5b5a7
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 2 deletions.
2 changes: 1 addition & 1 deletion plugins/flytekit-spark/flytekitplugins/spark/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -20,4 +20,4 @@
from .pyspark_transformers import PySparkPipelineModelTransformer
from .schema import SparkDataFrameSchemaReader, SparkDataFrameSchemaWriter, SparkDataFrameTransformer # noqa
from .sd_transformers import ParquetToSparkDecodingHandler, SparkToParquetEncodingHandler
from .task import Spark, new_spark_session # noqa
from .task import Databricks, Spark, new_spark_session # noqa
3 changes: 2 additions & 1 deletion plugins/flytekit-spark/flytekitplugins/spark/task.py
Original file line number Diff line number Diff line change
Expand Up @@ -118,7 +118,7 @@ def get_custom(self, settings: SerializationSettings) -> Dict[str, Any]:
spark_type=SparkType.PYTHON,
)
if isinstance(self.task_config, Databricks):
cfg = typing.cast(self.task_config, Databricks)
cfg = typing.cast(Databricks, self.task_config)
job._databricks_conf = cfg.databricks_conf
job._databricks_token = cfg.databricks_token
job._databricks_instance = cfg.databricks_instance
Expand Down Expand Up @@ -150,3 +150,4 @@ def pre_execute(self, user_params: ExecutionParameters) -> ExecutionParameters:

# Inject the Spark plugin into flytekits dynamic plugin loading system
TaskPlugins.register_pythontask_plugin(Spark, PysparkFunctionTask)
TaskPlugins.register_pythontask_plugin(Databricks, PysparkFunctionTask)

0 comments on commit 7b5b5a7

Please sign in to comment.