To debug why traces don't show up in the Phoenix UI, set the OTEL diagnostics log level to debug by exporting the environment variable `OTEL_LOG_LEVEL=debug`. This enables detailed OpenTelemetry logging for troubleshooting. Additionally, you can add a `ConsoleSpanExporter` to your tracer provider to print spans to stdout and verify if spans are being created and exported correctly in your application code.
Example:
```
from opentelemetry.sdk.trace.export import ConsoleSpanExporter, SimpleSpanProcessor
tracer_provider.add_span_processor(SimpleSpanProcessor(ConsoleSpanExporter()))
```
For further troubleshooting, ensure environment variables like `PHOENIX_COLLECTOR_ENDPOINT`, `PHOENIX_HOST`, and `PHOENIX_PORT` are set correctly, and check Phoenix server logs for errors or warnings. Would you like more detail?
Sources:
- <https://arize-ai.slack.com/archives/C04R3GXC8HK/p1725606714.609529|Slack: OTEL_LOG_LEVEL=debug>
- <https://arize-ai.slack.com/archives/C04R3GXC8HK/p1722778288.923159|Slack: ConsoleSpanExporter for debugging>