diff --git a/instrumentation/opentelemetry-instrumentation-aws-lambda/src/opentelemetry/instrumentation/aws_lambda/__init__.py b/instrumentation/opentelemetry-instrumentation-aws-lambda/src/opentelemetry/instrumentation/aws_lambda/__init__.py index 7dd8862f88..7a5b1891ee 100644 --- a/instrumentation/opentelemetry-instrumentation-aws-lambda/src/opentelemetry/instrumentation/aws_lambda/__init__.py +++ b/instrumentation/opentelemetry-instrumentation-aws-lambda/src/opentelemetry/instrumentation/aws_lambda/__init__.py @@ -95,7 +95,6 @@ def custom_event_context_extractor(lambda_event): TRACE_HEADER_KEY, AwsXRayPropagator, ) -from opentelemetry.semconv.resource import ResourceAttributes from opentelemetry.semconv.trace import SpanAttributes from opentelemetry.trace import ( Span, diff --git a/instrumentation/opentelemetry-instrumentation-aws-lambda/tests/test_aws_lambda_instrumentation_manual.py b/instrumentation/opentelemetry-instrumentation-aws-lambda/tests/test_aws_lambda_instrumentation_manual.py index 5324a2a079..2e84ee5a74 100644 --- a/instrumentation/opentelemetry-instrumentation-aws-lambda/tests/test_aws_lambda_instrumentation_manual.py +++ b/instrumentation/opentelemetry-instrumentation-aws-lambda/tests/test_aws_lambda_instrumentation_manual.py @@ -25,6 +25,10 @@ ) from opentelemetry.environment_variables import OTEL_PROPAGATORS +from opentelemetry.instrumentation._semconv import ( + _OTEL_SEMCONV_STABILITY_OPT_IN_KEY, + _OpenTelemetrySemanticConventionStability, +) from opentelemetry.instrumentation.aws_lambda import ( _HANDLER, _X_AMZN_TRACE_ID, @@ -32,10 +36,6 @@ OTEL_LAMBDA_DISABLE_AWS_CONTEXT_PROPAGATION, AwsLambdaInstrumentor, ) -from opentelemetry.instrumentation._semconv import ( - _OTEL_SEMCONV_STABILITY_OPT_IN_KEY, - _OpenTelemetrySemanticConventionStability, -) from opentelemetry.propagate import get_global_textmap from opentelemetry.propagators.aws.aws_xray_propagator import ( TRACE_ID_FIRST_PART_LENGTH, @@ -172,7 +172,7 @@ def test_active_tracing_semconv_opt_in(self): # Using Active tracing _X_AMZN_TRACE_ID: MOCK_XRAY_TRACE_CONTEXT_SAMPLED, # Opt into new semconv - _OTEL_SEMCONV_STABILITY_OPT_IN_KEY: "faas" + _OTEL_SEMCONV_STABILITY_OPT_IN_KEY: "faas", }, ) test_env_patch.start() @@ -205,7 +205,7 @@ def test_active_tracing_semconv_opt_in_dup(self): # Using Active tracing _X_AMZN_TRACE_ID: MOCK_XRAY_TRACE_CONTEXT_SAMPLED, # Opt into new semconv - _OTEL_SEMCONV_STABILITY_OPT_IN_KEY: "faas/dup" + _OTEL_SEMCONV_STABILITY_OPT_IN_KEY: "faas/dup", }, ) test_env_patch.start()