Skip to content
Judgment Labs
Esc
↑↓navigate↵open⌘Jpreview

SQLite3 Tracing

Trace SQLite3 spans with Judgment.

SQLite3 tracing uses the standard OpenTelemetry SQLite3 instrumentation and routes database spans through Judgment.

uv add judgeval opentelemetry-instrumentation-sqlite3
pip install judgeval opentelemetry-instrumentation-sqlite3

from judgeval import Tracer
from opentelemetry.instrumentation.sqlite3 import SQLite3Instrumentor

Tracer.init(project_name="sqlite3_app")
Tracer.registerOTELInstrumentation(SQLite3Instrumentor())

connection = sqlite3.connect(":memory:")
connection.execute("select 1").fetchone()
Tracer.force_flush()

Was this page helpful?