RAGAS telemetry DNS resolution failure can severely slow down evaluations
Summary
We observed that RAGAS evaluations can become extremely slow when the analytics/telemetry endpoint cannot be resolved:
t.explodinggradients.com
The DNS failure we see is:
Temporary failure in name resolution
We first noticed this in GitHub Actions, where RAGAS evaluation jobs started taking multiple hours and eventually timed out. We can also reproduce the DNS issue locally:
ping t.explodinggradients.com
returns:
ping: t.explodinggradients.com: Temporary failure in name resolution
Impact
The failed telemetry calls appear to introduce repeated wait/retry delays during RAGAS evaluation. In our case this caused:
- severe slowdown of evaluation runs,
- individual RAGAS job timeouts,
- CI runs eventually hitting the GitHub Actions timeout.
After disabling RAGAS telemetry, the same evaluation completed normally again.
Workaround
Explicitly disabling telemetry fixed the issue for us:
RAGAS_DO_NOT_TRACK=true
RAGAS_ANALYTICS_ENABLED=false
RAGAS_TELEMETRY_ENABLED=false
DO_NOT_TRACK=1
We set these as early as possible before importing/running RAGAS.
Expected behavior
Telemetry should be best-effort and should not block or significantly slow down evaluation when the telemetry endpoint cannot be resolved.
It would also be helpful to document the recommended environment variable for fully disabling RAGAS telemetry in CI environments.
Hey, I'd like to work on this! I traced the root cause — track() calls requests.post(..., timeout=1) but that timeout only covers TCP connect + read. DNS resolution happens before requests opens a socket, so it completely bypasses the timeout. When t.explodinggradients.com can't be resolved, the OS retries DNS for 15–30s per call, blocking evaluation the entire time. I have a fix in mind and will also address the env var confusion from the workaround section.
Can I be assigned to this?
I've submitted a fix in PR #2756.
Root cause: requests.post(timeout=1) doesn't cover DNS resolution — only TCP connect + read. When t.explodinggradients.com can't be resolved, the OS retries DNS for 15–30s per call, blocking the main thread entirely.
Fix: track() now fires in a daemon thread — telemetry is fire-and-forget and DNS failures never block evaluation. Also addresses #2603 by adding DO_NOT_TRACK=1 and DISABLE_TELEMETRY=1 support.