Estimated end-of-life date, accurate to within three months: 05-2027 See the support level definitions for more information.
This is a major-version release that contains many backwards-incompatible changes to public APIs. To find which of these your code relies on, follow the "deprecation warnings" instructions here.
dd-trace-py now includes an OpenFeature provider implementation, enabling feature flag evaluation through the OpenFeature API.
This integration is under active design and development. Functionality and APIs are experimental and may change without notice. For more information, see the Datadog documentation at https://docs.datadoghq.com/feature_flags/#overview
ddtrace.Pin object with mongoengine. With this change, the ddtrace library no longer directly supports mongoengine. Mongoengine will be supported through the pymongo integration.pytest_benchmark and pytest_bdd integrations. These plugins are now supported by the regular pytest integration.DD_DYNAMIC_INSTRUMENTATION_UPLOAD_FLUSH_INTERVAL variable.DD_EXCEPTION_DEBUGGING_ENABLED variable.Span.set_tag_str has been removed, use Span.set_tag instead.Span.set_struct_tag has been removed.Span.get_struct_tag has been removed.Span._pprint has been removedSpan.finished setter was removed, please use Span.finish() method instead.Tracer.on_start_span method has been removed.Tracer.deregister_on_start_span method has been removed.ddtrace.trace.Pin has been removed.Span.finish_with_ancestors was removed with no replacement.Span.set_tag typing is now set_tag(key: str, value: Optional[str] = None) -> NoneSpan.get_tag typing is now get_tag(key: str) -> Optional[str]Span.set_tags typing is now set_tags(tags: dict[str, str]) -> NoneSpan.get_tags typing is now get_tags() -> dict[str, str]Span.set_metric typing is now set_metric(key: str, value: int | float) -> NoneSpan.get_metric typing is now get_metric(key: str) -> Optional[int | float]Span.set_metrics typing is now set_metrics(metrics: Dict[str, int | float]) -> NoneSpan.get_metrics typing is now get_metrics() -> dict[str, int | float]Span.record_exception's timestamp and escaped parameters are removedLLMObs.annotate(), LLMObs.export_span(), LLMObs.submit_evaluation(), LLMObs.inject_distributed_headers(), and LLMObs.activate_distributed_headers() now raise exceptions instead of logging. LLM Observability auto-instrumentation is not affected.LLMObs.submit_evaluation_for() has been removed. Please use LLMObs.submit_evaluation() instead for submitting evaluations. To migrate:
LLMObs.submit_evaluation_for(...) users: rename to LLMObs.submit_evaluation(...)LLMObs.submit_evaluation_for(...) users: rename the span_context argument to span, i.e. LLMObs.submit_evaluation(span_context={"span_id": ..., "trace_id": ...}, ...) to LLMObs.submit_evaluation(span={"span_id": ..., "trace_id": ...}, ...)DD_PROFILING_STACK_V2_ENABLED is now removed.freezegun integration is now removed.opentracer packagegoogle_generativeai integration has been removed as the google_generativeai library has reached end-of-life.
As an alternative, you can use the recommended google_genai library and corresponding integration instead.tiktoken library, and instead
will default to having their token counts estimated if not explicitly provided in the OpenAI response object. To guarantee accurate streamed token metrics, set stream_options={"include_usage": True} in the OpenAI request.DD_DJANGO_TRACING_MINIMAL now defaults to true). Django ORM, cache, and template instrumentation are disabled by default to eliminate duplicate span creation since library integrations for database drivers (psycopg, MySQLdb, sqlite3), cache clients (redis, memcached), template renderers (Jinja2), and other supported libraries continue to be traced. This reduces performance overhead by removing redundant Django-layer instrumentation. To restore all Django instrumentation, set DD_DJANGO_TRACING_MINIMAL=false, or enable individual features using DD_DJANGO_INSTRUMENT_DATABASES=true, DD_DJANGO_INSTRUMENT_CACHES=true, and DD_DJANGO_INSTRUMENT_TEMPLATES=true.DD_DJANGO_INSTRUMENT_DATABASES=true (default false), database instrumentation now merges Django-specific tags into database driver spans created by supported integrations (psycopg, sqlite3, MySQLdb, etc.) instead of creating duplicate Django database spans. If the database cursor is not already wrapped by a supported integration, Django wraps it and creates a span. This change reduces overhead and duplicate spans while preserving visibility into database operations.ddtrace.settings package. Environment variables should be used to adjust settings.HttpPropagator.injectDEFAULT_RUNTIME_METRICS_INTERVAL.ddtrace.contrib.tornado module. Configure tracing using environment variables and import ddtrace.auto instead.urllib3 and requests. It does not require enabling APM instrumentation for urllib3 anymore.threading.RLock (reentrant lock) profiling. The Lock profiler now tracks both threading.Lock and threading.RLock usage, providing comprehensive lock contention visibility for Python applications.version argument to LLMObs.pull_datasetversion and latest_version to provide information on the version of the dataset that is being worked with and the latest global version of the dataset, respectivelyLock, RLock, Event).HTTPS_PROXY.assessment argument in submit_evaluation().langchain integration would incorrectly mark Azure OpenAI calls as duplicate llm operations even if the openai integration was enabled.DD_PROFILING_API_TIMEOUT doesn't have any effect, and is marked to be removed in upcoming 4.0 release. New environment variable DD_PROFILING_API_TIMEOUT_MS is introduced to configure timeout for uploading profiles to the backend. The default value is 10000 ms (10 seconds)_acquire method of the Lock profiler (note: this only occurs when assertions are enabled.)version field. The version field is now omitted unless explicitly set by the user.
assessment now refers to whether the evaluation itself passes or fails according to your application, rather than the validity of the evaluation result.
The langchain integration will trace Azure OpenAI spans as workflow spans if there is an equivalent llm span from the openai integration.IndexError.async for model in client.models.list()) caused a TypeError: 'async for' requires an object with __aiter__ method, got coroutine. See issue #14574.KeyError exceptions in test runs when gevent is detected within the environment.ray.init().ray.data._internal to the module denylist.ValueError: Formatting field not found in record: 'dd.service'.ResourceWarning in multiprocess scenarios.wrapt library dependency from the Lock Profiler implementation, improving performance and reducing overhead during lock instrumentation.Fetched April 3, 2026