Skip to content

Commit c7b000d

Browse files
committed
remove erroneous "type" attribute from asgi, fix open-telemetry#2055
1 parent c68d0fd commit c7b000d

File tree

1 file changed

+1
-2
lines changed
  • instrumentation/opentelemetry-instrumentation-asgi/src/opentelemetry/instrumentation/asgi

1 file changed

+1
-2
lines changed

Diff for: instrumentation/opentelemetry-instrumentation-asgi/src/opentelemetry/instrumentation/asgi/__init__.py

+1-2
Original file line numberDiff line numberDiff line change
@@ -666,7 +666,6 @@ async def otel_receive():
666666
if receive_span.is_recording():
667667
if message["type"] == "websocket.receive":
668668
set_status_code(receive_span, 200)
669-
receive_span.set_attribute("type", message["type"])
670669
return message
671670

672671
return otel_receive
@@ -697,7 +696,7 @@ async def otel_send(message: dict[str, Any]):
697696
elif message["type"] == "websocket.send":
698697
set_status_code(server_span, 200)
699698
set_status_code(send_span, 200)
700-
send_span.set_attribute("type", message["type"])
699+
701700
if (
702701
server_span.is_recording()
703702
and server_span.kind == trace.SpanKind.SERVER

0 commit comments

Comments
 (0)