Back to Home
Dify Langfuse traces only show input and output, not internal nodes
Troubleshooting7 min readSource: Admesh Engineering

Dify Langfuse traces only show input and output, not internal nodes

Langfuse records only Dify workflow inputs and outputs while node traces are missing. Check Celery worker concurrency and logs before touching Langfuse config.

The symptom

You deploy Dify and Langfuse locally, follow the documented tracing setup, and run a workflow. In Langfuse you see one trace per run with the workflow input and the final output, but nothing in between. There are no per-node entries, no LLM generations for the model calls inside the workflow, and no spans for tool, code, or knowledge-retrieval nodes.

The shape of the problem matters: tracing is not broken end to end. A trace exists, it has a start and an end, and the payload is readable. What is missing is the middle of the tree. That distinction separates a credential or endpoint problem from a data-loss problem during execution.

  • A trace appears in Langfuse for each workflow run.
  • Input and output are populated.
  • No child observations appear for internal nodes.
  • No error is surfaced in the Dify UI or in the Langfuse UI.

Why it happens

Rank the causes from most to least likely, and confirm each one before changing anything.

  • Celery worker concurrency and execution timing (most likely). Replies in the thread argue that Dify moved workflow execution onto Celery workers and that a default concurrency of 1 can cause node execution records to be written or read in the wrong order. Confirm by checking the worker container logs during a run and by comparing behaviour with a higher concurrency setting.
  • Node data read from an in-memory cache. A reply describes a race in the Celery workflow repository where node execution data is fetched only from an in-memory cache, so the tracer can miss nodes that have already moved on. Confirm by checking whether the missing nodes vary between runs of the same workflow.
  • A platform-level bug rather than a Langfuse problem. One reply says the issue has been seen across multiple Dify versions and also affects LangSmith tracing. Confirm by pointing Dify at a different tracing backend; if node spans are still missing, Langfuse is not the cause.
  • A genuine configuration gap. This is the least likely given that a trace exists at all, but confirm by re-checking that the tracing provider is enabled for the app and that the keys in the environment match the project you are inspecting.

How to fix it

Work through these in order and stop when node spans appear.

  1. Reproduce with a minimal workflow: one LLM node between a start and an end node. This removes branching and parallel execution from the picture.
  2. Open the Celery worker logs while the workflow runs. With Docker, use docker compose logs -f on the worker service (or the container name from your compose file) and watch for exceptions or retries around the time of the run.
  3. Raise the worker concurrency above 1 and restart the worker, then rerun the minimal workflow. If node spans appear, the timing hypothesis is supported.
  4. Run the same workflow several times and note which nodes go missing. Randomly missing nodes point to a race; consistently missing nodes point to configuration or an unsupported node type.
  5. Switch Dify's tracing provider to a different backend for one run. If internal nodes are also missing there, treat it as a Dify-side issue and check the project's issue tracker for your version.
  6. If you need node-level detail immediately and cannot wait for a fix, add explicit logging inside the workflow or split the workflow into smaller apps so each run maps to fewer nodes.

When this is not the cause

If no trace appears in Langfuse at all, this is a different problem: check the tracing endpoint, the public and secret keys, and whether the app has tracing enabled. If traces appear but only for some apps, compare the tracing settings per app rather than the worker.

If only LLM nodes are missing while other nodes appear, look at the model provider configuration rather than Celery, since generation records depend on the model call succeeding. If traces stop after a Dify upgrade, note the version you moved from and to, and test the previous version before filing a report.

Finally, if the Langfuse project you are inspecting is not the one the keys belong to, you will see partial or empty data with no error. Verify the project name in the Langfuse UI against the keys in your Dify environment.

How to apply this with Admesh

While you debug tracing, keep the model side stable so you can tell workflow problems apart from provider problems. Point Dify's OpenAI-compatible provider at the Admesh base URL https://api.admesh.ai/v1 and use a single Admesh API key. That way a failing model call shows up as a model error rather than as a missing trace.

If your workflow uses Anthropic-style calls, use the Anthropic-compatible endpoint https://api.admesh.ai/v1/messages instead. One key and one balance cover OpenAI, Anthropic, Google, DeepSeek, Qwen, Moonshot, Zhipu, and MiniMax families, so you can swap the model inside a node without adding credentials to Dify.

Create the key in the console at https://console.admesh.ai, then check the model catalog and current pricing at https://admesh.ai/models before you pin a model in a node. Setup details are at https://docs.admesh.ai.

Run the minimal one-node workflow against Admesh first. If node spans appear with a single provider and disappear when you add nodes, the tracing issue is in Dify's execution path, not in the model provider.

Admesh API docs →

FAQ

Does Dify 1.13.0 lose Langfuse node traces because of a Langfuse misconfiguration?
Probably not. The thread shows a trace being created with input and output, which means the connection works. The replies point at Dify's Celery-based workflow execution instead, though the thread does not confirm a fix.
How do I check Celery worker logs in a Docker deployment?
Find the worker service name in your compose file and follow its logs with docker compose logs -f followed by the service name. Run a workflow at the same time and look for exceptions or retries.
Will raising Celery concurrency fix missing node spans?
It is a hypothesis from the thread, not a confirmed fix. Test it on a minimal workflow and compare runs; if spans appear consistently, the timing explanation is supported.
The same problem happens with LangSmith. What does that mean?
A reply reports the issue with LangSmith too, which suggests the tracing backend is not the deciding factor. Verify by switching backends for one run and comparing the node coverage.

References

Call these models through one gateway

Admesh provides a unified OpenAI-compatible API: one Base URL and one key for Claude, GPT, DeepSeek and more. New accounts get trial credit that never expires.