eladkal commented on code in PR #31576:
URL: https://github.com/apache/airflow/pull/31576#discussion_r1207767945
##########
scripts/in_container/run_provider_yaml_files_check.py:
##########
@@ -306,22 +311,6 @@ def check_hook_classes(yaml_files: dict[str, dict]):
)
-def check_trigger_classes(yaml_files: dict[str, dict]):
- print("Checking triggers classes belong to package, exist and are classes")
- resource_type = "triggers"
- for yaml_file_path, provider_data in yaml_files.items():
- provider_package =
pathlib.Path(yaml_file_path).parent.as_posix().replace("/", ".")
- trigger_classes = {
- name
- for trigger_class in provider_data.get(resource_type, {})
- for name in trigger_class["class-names"]
- }
- if trigger_classes:
- check_if_objects_exist_and_belong_to_package(
- trigger_classes, provider_package, yaml_file_path,
resource_type, ObjectType.CLASS
- )
Review Comment:
This is not needed. It was aim to do the same as with `check_hook_classes`
function but this function is to tests the connections of the hook. This is why
we have it only for hooks.
I removed this function and renamed `check_hook_classes` to
`check_hook_connection_classes` to avoid future confusion.
--
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]