Register a new environment variable / configuration option in dd-trace-py. Use whenever you add (or rename) a DD_*/_DD_*/OTEL_*/DATADOG_* environment variable so it is documented, validated, and tracked for cross-language feature parity. Covers supported-configurations.json, the generated _supported_configurations.py module, docs/configuration.rst, and the feature-parity registry hand-off.
Use this skill whenever a code change introduces a new environment variable
(or renames/aliases an existing one). In dd-trace-py every DD_*, _DD_*,
OTEL_*, or DATADOG_* variable accessed under ddtrace/ MUST be registered,
or the supported_configurations CI check fails.
Typical trigger: you just added something like
DDConfig.var(bool, AI_GUARD.ENV_OPENAI_ENABLED, default=True) in a settings
module and need to make CI / docs happy.
supported-configurations.json is the source of truth. Edit it by hand;
everything else is generated or verified from it.ddtrace/internal/settings/_supported_configurations.py —
it is AUTO-GENERATED. Run the script to regenerate it.supportedConfigurations
object (the generator sorts the Python module, but keep the JSON tidy too).docs/configuration.rst under the
correct product section.supported-configurations.jsonFind the right alphabetical slot and add a single-element array. Set type to
mirror the DDConfig.var(...) type. Do NOT infer the implementation letter
from neighbouring variables — it is owned by the central Configuration Registry
(see step 6). Use "A" for a brand-new key; if the key already exists in the
registry, reuse its letter, and if a maintainer must create a new
implementation version (because the type/default differs from an existing
cross-language entry), reference that version's letter.
"DD_AI_GUARD_OPENAI_ENABLED": [
{
"implementation": "A",
"type": "boolean",
"default": "true"
}
],Field notes:
type: one of boolean, string, int, etc. — mirror the DDConfig.var(...) type.default: the string form of the default ("true", "16", or null
for no default). Must match the code default exactly.implementation: the version letter assigned by the central Configuration
Registry (step 6), NOT inferred from neighbouring vars. A product prefix like
DD_TRACE_/DD_APPSEC_ legitimately mixes multiple letters, so copying a
sibling can write the wrong value and only the central CI will catch it.aliases, deprecated, sensitive
(excludes the value from config telemetry). Add these only when applicable.python scripts/supported_configurations.pyThis rewrites ddtrace/internal/settings/_supported_configurations.py
(SUPPORTED_CONFIGURATIONS, CONFIGURATION_ALIASES,
DEPRECATED_CONFIGURATIONS, SENSITIVE_CONFIGURATIONS) and verifies that every
env var accessed in ddtrace/ is registered.
python scripts/supported_configurations.py --checkExpected output:
_supported_configurations.py is up to date.
Registry is complete (NNN entries, no unregistered vars).This is the same check CI runs. If it reports unregistered vars, you missed an entry in step 1.
docs/configuration.rstAdd an entry under the appropriate product heading using the
.. ddtrace-configuration-options:: directive. Match the surrounding style.
DD_AI_GUARD_OPENAI_ENABLED:
type: Boolean
default: True
description: |
Per-provider kill switch for AI Guard auto-instrumentation of the OpenAI SDK.
When set to ``False``, disables AI Guard instrumentation for OpenAI only.Include version_added: if the option is gated to a specific release.
New public configuration is user-facing, so add a Reno fragment (use the
releasenote skill). Skip only for purely internal/private vars.
The agent CANNOT do this — it is an external web application. Tell the user:
⚠️ Action required: Add this configuration to the cross-language feature-parity registry so it is tracked across tracer languages: https://feature-parity.us1.prod.dog/#/configurations?viewType=configurations
supported-configurations.json (correct type/default/implementation).python scripts/supported_configurations.py run (module regenerated).python scripts/supported_configurations.py --check passes.docs/configuration.rst under the right section.--check step is what CI enforces; always run it before committing.default in the JSON is a string (or null), even for ints/booleans.ddtrace/, the
completeness check won't force registration — but register it anyway if it is
a real, documented configuration option.alias rather than deleting it, to avoid
breaking existing deployments.57aff59
If you maintain this skill, you can claim it as your own. Once claimed, you can manage eval scenarios, bundle related skills, attach documentation or rules, and ensure cross-agent compatibility.