Only set up exporters if providers are properly set (#530)
This PR fixes the issue where DBOS would throw an exception if `enable_otlp` is set to `True` but the logger/tracer providers weren't set. Instead of crashing the entire app, it'll log a warning after this change. Also fixed an issue where `DBOS.trace` being `None` (when OTLP tracer wasn't set) could crash the FastAPI app. It should only set the status code if it can find an active span.
Q
Qian Li committed
d05e3642a30352a8e7ddfaee70fa7cc99d5be20c
Parent: 2e15ab5
Committed by GitHub <noreply@github.com>
on 12/2/2025, 1:10:47 AM