Troubleshooting
Nothing Is Sent To The Backend
Check these first:- did you call
$telemetry->flush()at the end of the run - did you attach
RuntimeEventBridgeto the same event bus used by the runtime - did you add the right projectors for the packages in play
- are your backend credentials and endpoints set correctly
flush(), exporters can keep data in memory and never send it.
Spans Are Missing Or Not Connected
Usually this means one of two things:- different parts of the app are using different event dispatchers
- the relevant runtime projector is missing
agents emits on one
event bus and polyglot emits on another, you will get broken or partial traces.
Check Payloads Locally First
For local debugging, useOtelExporter without a transport and inspect what it
captured:
HTTP Export Errors
Transport errors throw explicit exceptions. Typical cases:- bad token or key: HTTP 4xx
- backend unavailable: HTTP 5xx
- invalid endpoint or network issue: transport exception before a valid status
Langfuse-Specific Note
Langfuse export goes to:/api/public/otel/v1/traces
LangfuseConfig the base URL, not the full traces URL.
Logfire-Specific Note
Logfire export uses the OTLP base endpoint. GiveLogfireConfig the base OTLP
URL, not a full /v1/traces or /v1/metrics path.
The example helper in examples/_support/logfire.php normalizes this for you.
Good Reference Points
If your own setup is not working, compare it with:examples/_support/langfuse.phpexamples/_support/logfire.phpexamples/D05_AgentTroubleshooting/TelemetryLangfuse/run.phpexamples/D05_AgentTroubleshooting/TelemetryLogfire/run.php