From b44bd5548d97bffc15aafbb250346d81ecce2c9f Mon Sep 17 00:00:00 2001 From: Liudmila Molkova Date: Wed, 6 Dec 2023 20:45:56 -0800 Subject: [PATCH] lint --- .../src/opentelemetry/semconv/model/semantic_attribute.py | 4 ++-- .../src/opentelemetry/semconv/templating/markdown/__init__.py | 2 +- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/semantic-conventions/src/opentelemetry/semconv/model/semantic_attribute.py b/semantic-conventions/src/opentelemetry/semconv/model/semantic_attribute.py index 34523e72..e27f654a 100644 --- a/semantic-conventions/src/opentelemetry/semconv/model/semantic_attribute.py +++ b/semantic-conventions/src/opentelemetry/semconv/model/semantic_attribute.py @@ -352,7 +352,7 @@ def is_template_type(attr_type: str): attr_type.startswith(TEMPLATE_PREFIX) and attr_type.endswith(TEMPLATE_SUFFIX) and AttributeType.is_simple_type( - attr_type[len(TEMPLATE_PREFIX): len(attr_type) - len(TEMPLATE_SUFFIX)] + attr_type[len(TEMPLATE_PREFIX) : len(attr_type) - len(TEMPLATE_SUFFIX)] ) ) @@ -360,7 +360,7 @@ def is_template_type(attr_type: str): def get_instantiated_type(attr_type: str): if AttributeType.is_template_type(attr_type): return attr_type[ - len(TEMPLATE_PREFIX): len(attr_type) - len(TEMPLATE_SUFFIX) + len(TEMPLATE_PREFIX) : len(attr_type) - len(TEMPLATE_SUFFIX) ] if AttributeType.is_simple_type(attr_type): return attr_type diff --git a/semantic-conventions/src/opentelemetry/semconv/templating/markdown/__init__.py b/semantic-conventions/src/opentelemetry/semconv/templating/markdown/__init__.py index 59d8a74a..f708f168 100644 --- a/semantic-conventions/src/opentelemetry/semconv/templating/markdown/__init__.py +++ b/semantic-conventions/src/opentelemetry/semconv/templating/markdown/__init__.py @@ -490,7 +490,7 @@ def _render_single_file(self, content: str, md: str, output: io.StringIO): # We should not fail here since we would detect this earlier # But better be safe than sorry raise ValueError(f"Semantic Convention ID {semconv_id} not found") - output.write(content[last_match: match.start(0)]) + output.write(content[last_match : match.start(0)]) self._render_group(semconv, parameters, output) end_match = self.p_end.search(content, last_match) if not end_match: