diff --git a/python_modules/dagster-graphql/dagster_graphql/schema/pipelines/pipeline.py b/python_modules/dagster-graphql/dagster_graphql/schema/pipelines/pipeline.py index cfc57f2d28ef5..f078a8cb761f9 100644 --- a/python_modules/dagster-graphql/dagster_graphql/schema/pipelines/pipeline.py +++ b/python_modules/dagster-graphql/dagster_graphql/schema/pipelines/pipeline.py @@ -636,10 +636,7 @@ def resolve_hasRunMetricsEnabled(self, graphene_info: ResolveInfo): return False run_tags = self.dagster_run.tags - for tag in RUN_METRIC_TAGS: - if get_boolean_tag_value(run_tags.get(tag)): - return True - return False + return any(get_boolean_tag_value(run_tags.get(tag) for tag in RUN_METRIC_TAGS)) class GrapheneIPipelineSnapshotMixin: