## TL;DR

Langchain Instrumentation ### 📜 Description Trace graph is incorrect, the span created inside the nodes are not listed under the node spans, they list under parent/root span. ### 👟 Reproduction steps Run the project, with opentelmetry-instrumentation, below is the command which i'm using to run the code opentelemetry-instrument \ --traces_exporter otlp \ --metrics_exporter none \ --service_name test_service \ --exporter_otlp_endpoint YOUR_HOST:4317 \ --exporter_otlp_insecure true \ poetry run python test_agent.

## Steps

1. Issue traceloop/openllmetry#3203 (closed, 9 comments): ### Which component is this bug for? Langchain Instrumentation ### 📜 Description Trace graph is incorrect, the span created inside the nodes are not listed under the node spans, they list under parent/root span. ### 👟 Reproduction steps Run the project, with opentelmetry-instrumentation, below is the command which i'm using to run the code opentelemetry-instrument \ --traces_exporter otlp \ --metrics_exporter none \ --service_name test_service \ --exporter_otlp_endpoint YOUR_HOST:4317 \ --exporter_otlp_insecure true \ poetry run python test_agent.

2. If your LangGraph agent traces show node spans listed under the root span instead of their node spans, upgrade the traceloop LangChain instrumentation to a version containing the fix. The maintainers fixed it via LANGGRAPH_GRAPH_SPAN_KEY context propagation and closed the issue after landing it in main.

## When to use

You are seeing this: Issue traceloop/openllmetry#3203 (closed, 9 comments): ### Which component is this bug for? Use this skill when you run into "🐛 Bug Report: Trace graph is incorrectly stitched for Langgraph agents".

## When not to use

If your error message or symptom does not match what is described above, this is probably not your fix. Search for your exact error text instead of forcing this one to fit.

## Versions

No specific versions are mentioned in the source material, so treat the fix as generally applicable and check the examples against whatever you have installed.

## Why this happens

The original report does not dig into a root cause. It documents the symptom and the fix that resolved it.

## Sources

- https://github.com/traceloop/openllmetry/issues/3203
