ashb commented on code in PR #64523:
URL: https://github.com/apache/airflow/pull/64523#discussion_r3427111204


##########
airflow-core/src/airflow/configuration.py:
##########
@@ -407,6 +408,28 @@ def _validate_enums(self):
                         f"{value!r}. Possible values: {', 
'.join(enum_options)}."
                     )
 
+    def _validate_api_path_prefix_to_surface(self):
+        """Validate the mapping used to assign API metrics to surfaces."""
+        section, key = "metrics", "api_path_prefix_to_surface"
+        if not self.has_option(section, key):
+            return
+
+        path_prefix_to_surface = self.getjson(section, key)
+        if not isinstance(path_prefix_to_surface, dict):
+            raise AirflowConfigException(f"[{section}] {key} must be a JSON 
object")

Review Comment:
   (or similar)



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

Reply via email to