Skip to content

Commit cbe9f07

Browse files
committed
fix duplicated calls
1 parent 26cdef0 commit cbe9f07

File tree

1 file changed

+5
-3
lines changed
  • metadata-ingestion/src/datahub/ingestion/source

1 file changed

+5
-3
lines changed

metadata-ingestion/src/datahub/ingestion/source/mlflow.py

+5-3
Original file line numberDiff line numberDiff line change
@@ -299,7 +299,9 @@ def _get_dataset_input_workunits(self, run: Run) -> Iterable[MetadataWorkUnit]:
299299
source_type = dataset_input.dataset.source_type
300300
dataset_tags = {k[1]: v[1] for k, v in dataset_input.tags}
301301
dataset = dataset_input.dataset
302-
platform = self._get_dataset_platform_from_source_type(source_type)
302+
formatted_platform = self._get_dataset_platform_from_source_type(
303+
source_type
304+
)
303305
custom_properties = dataset_tags
304306
formatted_schema = self._get_dataset_schema(dataset.schema)
305307
# If the schema is not formatted, pass the schema as a custom property
@@ -308,7 +310,7 @@ def _get_dataset_input_workunits(self, run: Run) -> Iterable[MetadataWorkUnit]:
308310
# If the dataset is local or code, we create a local dataset reference
309311
if source_type in ("local", "code"):
310312
local_dataset_reference = Dataset(
311-
platform=platform,
313+
platform=formatted_platform,
312314
name=dataset.name,
313315
schema=formatted_schema,
314316
custom_properties=custom_properties,
@@ -318,7 +320,7 @@ def _get_dataset_input_workunits(self, run: Run) -> Iterable[MetadataWorkUnit]:
318320
# Otherwise, we create a hosted dataset reference and a hosted dataset
319321
else:
320322
hosted_dataset = Dataset(
321-
platform=self._get_dataset_platform_from_source_type(source_type),
323+
platform=formatted_platform,
322324
name=dataset.name,
323325
schema=formatted_schema,
324326
custom_properties=dataset_tags,

0 commit comments

Comments
 (0)