You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@airflow.apache.org by GitBox <gi...@apache.org> on 2021/02/21 20:40:29 UTC

[GitHub] [airflow] mik-laj commented on a change in pull request #14280: Add plugins endpoint to the REST API

mik-laj commented on a change in pull request #14280:
URL: https://github.com/apache/airflow/pull/14280#discussion_r579862498



##########
File path: airflow/plugins_manager.py
##########
@@ -427,3 +427,39 @@ def integrate_macros_plugins() -> None:
             # Register the newly created module on airflow.macros such that it
             # can be accessed when rendering templates.
             setattr(macros, plugin.name, macros_module)
+
+
+def get_plugin_info(attrs_to_dump: Optional[List[str]] = None):
+    """
+    Dump plugins attributes
+
+    :param attrs_to_dump: A list of plugin attributes to dump
+    :type attrs_to_dump: List
+    """
+    plugins_attributes_to_dump = [
+        "hooks",
+        "executors",
+        "macros",
+        "admin_views",
+        "flask_blueprints",
+        "menu_links",
+        "appbuilder_views",
+        "appbuilder_menu_items",
+        "global_operator_extra_links",
+        "operator_extra_links",
+        "source",
+    ]

Review comment:
       when it is a set, the order of the elements is maintained, which might be expected when building the user interface.




----------------------------------------------------------------
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.

For queries about this service, please contact Infrastructure at:
users@infra.apache.org