phanikumv commented on code in PR #26345:
URL: https://github.com/apache/airflow/pull/26345#discussion_r971030906
##########
airflow/providers/microsoft/azure/hooks/data_factory.py:
##########
@@ -479,12 +481,121 @@ def delete_dataset(
Delete the dataset.
:param dataset_name: The dataset name.
- :param resource_group_name: The dataset name.
+ :param resource_group_name: The resource group name.
:param factory_name: The factory name.
:param config: Extra parameters for the ADF client.
"""
self.get_conn().datasets.delete(resource_group_name, factory_name,
dataset_name, **config)
+ @provide_targeted_factory
+ def get_dataflow(
+ self,
+ dataflow_name: str,
+ resource_group_name: str,
+ factory_name: str,
Review Comment:
@josh-fell - changing the type defn's to `Optional` in other methods without
changing in `_dataflow_exists()` leads to below errors
```
Run mypy for
providers.................................................................Failed
- hook id: run-mypy
- exit code: 1
airflow/providers/microsoft/azure/hooks/data_factory.py:545: error: Argument
2
to "_dataflow_exists" of "AzureDataFactoryHook" has incompatible type
"Optional[str]"; expected "str" [arg-type]
resource_group_name,
^
airflow/providers/microsoft/azure/hooks/data_factory.py:546: error: Argument
3
to "_dataflow_exists" of "AzureDataFactoryHook" has incompatible type
"Optional[str]"; expected "str" [arg-type]
factory_name,
^
airflow/providers/microsoft/azure/hooks/data_factory.py:574: error: Argument
2
to "_dataflow_exists" of "AzureDataFactoryHook" has incompatible type
"Optional[str]"; expected "str" [arg-type]
if self._dataflow_exists(dataflow_name, resource_group_name, f...
^
airflow/providers/microsoft/azure/hooks/data_factory.py:574: error: Argument
3
to "_dataflow_exists" of "AzureDataFactoryHook" has incompatible type
"Optional[str]"; expected "str" [arg-type]
...lf._dataflow_exists(dataflow_name, resource_group_name, factory_name):
^
Found 4 errors in 1 file (checked 1 source file)
```
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]