No traces appear
Your app ran but no trace shows up in FutureAGI Observe. The usual causes are an unflushed short-lived process, the wrong project_type, missing FI_API_KEY or FI_SECRET_KEY, or a date-picker window that is too narrow.
Symptom
You instrumented your app with traceAI and ran it, but no trace shows up in the trace explorer. Typically:
- A request ran with no error, but no new row appears in the trace list.
- A short script (a one-off
python app.py) never produces a trace. - Traces appeared before but stopped after a code change.
The most common cause is a short-lived process that exited before its spans flushed; the next most common are the wrong project_type, missing keys, or a date window that hides the trace. Work the checks below in order — the first one fixes the large majority of cases.
Quick checks
- The process stays alive long enough to export, or calls
force_flush()before exiting. FI_API_KEYandFI_SECRET_KEYare set to this workspace’s keys.register()is called with the correctproject_typeandproject_name, before the framework client is created.- The date picker is widened to Today (not the default 7-day window) and Auto refresh is on.
Causes and fixes
| Cause | What you see | Fix |
|---|---|---|
| Short-lived process not flushed (most common) | A one-off script runs clean but no trace appears; long-running services are fine | Call trace_provider.force_flush() before the process ends, or pass batch=False to register(). |
Wrong project_type | App runs, keys are valid, but traces never land in the project you expect | Set project_type=ProjectType.OBSERVE (and the matching project_name) in register(). |
Missing FI_API_KEY / FI_SECRET_KEY | Export fails or is silently dropped; nothing reaches Observe | Set both env vars to this workspace’s keys before the app starts. |
| Instrumented after the client was created | Some or all spans never emit because the client wasn’t wrapped | Call register() and the instrumentor before constructing the framework client. |
| Date-picker window too narrow | The trace exists but is filtered out of the view | Widen the date range to Today and enable Auto refresh. |
Diagnostic commands
Confirm the keys are present in the environment the app actually runs in:
env | grep -E "FI_API_KEY|FI_SECRET_KEY"
Force a flush in a short script so spans are exported before the process exits:
from fi_instrumentation import register
from fi_instrumentation.fi_types import ProjectType
trace_provider = register(
project_type=ProjectType.OBSERVE,
project_name="my-project",
)
# ... run one request ...
trace_provider.force_flush()
Minimal smoke test
Send one request, then open Observe → your project → Tracing with Auto refresh on and the date range widened to Today. A new trace should appear within seconds, Status OK, with input, output, latency, and model populated. If it doesn’t, recheck the causes above in order.
Prevent recurrence
- Add
trace_provider.force_flush()to short scripts and job runners. - Call
register()+instrument()once at startup, before any client is built — see Set up tracing. - Keep
FI_API_KEY,FI_SECRET_KEY, andproject_typein your startup config so they can’t drift per environment.
If you’re still stuck, collect your project_name, a request timestamp, your installed fi-instrumentation-otel and instrumentor versions, and any stderr, and contact support@futureagi.com.
Next steps
Questions & Discussion