Skip to content

Conversation

@ArmentaRoberto
Copy link
Contributor

What changed

  • Fixes a regression where datadog.agent.check_ready was emitted without a check_name tag value.

  • Ensures the name used for reportPy3Warnings() is the successfully loaded module name, with a fallback to config.Name.

Why

  • Between 7.72 and 7.73, a scoping/flow change caused the value passed to reportPy3Warnings() to be empty in some cases, resulting in missing check_name tag values and collapsing linted-state tracking.

How

  • Track the successfully loaded module name (loadedName) at the get_class(...) success point.

  • Use loadedName when calling reportPy3Warnings().

  • Fallback to config.Name if loadedName is unexpectedly empty.

Testing / QA plan

  • Repro on an affected Agent build where datadog.agent.check_ready is present but lacks check_name.

  • Run Agent with a Python check that triggers the reportPy3Warnings() path.

  • Verify in Metrics Explorer that datadog.agent.check_ready includes check_name:<expected>.

- Fixed regression introduced on 7.73 where check_name was not being returned on datadog.agent.check_ready
python: add release note for check_ready check_name tag fix
@ArmentaRoberto ArmentaRoberto requested review from a team as code owners January 30, 2026 00:52
@github-actions github-actions bot added team/agent-runtimes short review PR is simple enough to be reviewed quickly labels Jan 30, 2026
@ArmentaRoberto ArmentaRoberto changed the title [TEEP-4568] fix(python): restore check_name tag on datadog.agent.check_ready [TEEP-4568] [AGENT-15468] fix(python): restore check_name tag on datadog.agent.check_ready Jan 30, 2026
@ArmentaRoberto ArmentaRoberto added the qa/done QA done before merge and regressions are covered by tests label Jan 30, 2026
@agent-platform-auto-pr
Copy link
Contributor

Static quality checks

✅ Please find below the results from static quality gates
Comparison made with ancestor 681899c
📊 Static Quality Gates Dashboard

31 successful checks with minimal change (< 2 KiB)
Quality gate Current Size
agent_deb_amd64 748.049 MiB
agent_deb_amd64_fips 708.157 MiB
agent_heroku_amd64 325.593 MiB
agent_msi 659.741 MiB
agent_rpm_amd64 748.033 MiB
agent_rpm_amd64_fips 708.141 MiB
agent_rpm_arm64 727.128 MiB
agent_rpm_arm64_fips 689.721 MiB
agent_suse_amd64 748.033 MiB
agent_suse_amd64_fips 708.141 MiB
agent_suse_arm64 727.128 MiB
agent_suse_arm64_fips 689.721 MiB
docker_agent_amd64 810.525 MiB
docker_agent_arm64 814.215 MiB
docker_agent_jmx_amd64 1001.403 MiB
docker_agent_jmx_arm64 993.813 MiB
docker_cluster_agent_amd64 180.824 MiB
docker_cluster_agent_arm64 196.669 MiB
docker_cws_instrumentation_amd64 7.135 MiB
docker_cws_instrumentation_arm64 6.689 MiB
docker_dogstatsd_amd64 38.414 MiB
docker_dogstatsd_arm64 36.749 MiB
dogstatsd_deb_amd64 29.630 MiB
dogstatsd_deb_arm64 27.802 MiB
dogstatsd_rpm_amd64 29.630 MiB
dogstatsd_suse_amd64 29.630 MiB
iot_agent_deb_amd64 42.751 MiB
iot_agent_deb_arm64 39.872 MiB
iot_agent_deb_armhf 40.442 MiB
iot_agent_rpm_amd64 42.751 MiB
iot_agent_suse_amd64 42.751 MiB
On-wire sizes (compressed)
Quality gate Change Size (prev → curr → max)
agent_deb_amd64 +12.55 KiB (0.01% increase) 182.840 → 182.852 → 184.810
agent_deb_amd64_fips +11.39 KiB (0.01% increase) 174.303 → 174.314 → 177.560
agent_heroku_amd64 -3.56 KiB (0.00% reduction) 87.291 → 87.287 → 88.450
agent_msi -36.0 KiB (0.02% reduction) 142.449 → 142.414 → 143.300
agent_rpm_amd64 +3.35 KiB (0.00% increase) 185.778 → 185.782 → 188.160
agent_rpm_amd64_fips -40.4 KiB (0.02% reduction) 176.739 → 176.699 → 178.900
agent_rpm_arm64 -16.98 KiB (0.01% reduction) 168.388 → 168.371 → 169.930
agent_rpm_arm64_fips +4.7 KiB (0.00% increase) 160.788 → 160.793 → 163.120
agent_suse_amd64 +3.35 KiB (0.00% increase) 185.778 → 185.782 → 188.160
agent_suse_amd64_fips -40.4 KiB (0.02% reduction) 176.739 → 176.699 → 178.900
agent_suse_arm64 -16.98 KiB (0.01% reduction) 168.388 → 168.371 → 169.930
agent_suse_arm64_fips +4.7 KiB (0.00% increase) 160.788 → 160.793 → 163.120
docker_agent_amd64 neutral 275.087 MiB → 277.400
docker_agent_arm64 neutral 262.678 MiB → 266.040
docker_agent_jmx_amd64 neutral 343.720 MiB → 346.020
docker_agent_jmx_arm64 +9.97 KiB (0.00% increase) 327.294 → 327.304 → 330.660
docker_cluster_agent_amd64 neutral 63.874 MiB → 64.510
docker_cluster_agent_arm64 neutral 60.136 MiB → 61.170
docker_cws_instrumentation_amd64 neutral 2.994 MiB → 3.330
docker_cws_instrumentation_arm64 neutral 2.726 MiB → 3.090
docker_dogstatsd_amd64 neutral 14.863 MiB → 15.820
docker_dogstatsd_arm64 neutral 14.202 MiB → 14.830
dogstatsd_deb_amd64 neutral 7.831 MiB → 8.790
dogstatsd_deb_arm64 neutral 6.718 MiB → 7.710
dogstatsd_rpm_amd64 neutral 7.844 MiB → 8.800
dogstatsd_suse_amd64 neutral 7.844 MiB → 8.800
iot_agent_deb_amd64 neutral 11.211 MiB → 12.040
iot_agent_deb_arm64 neutral 9.583 MiB → 10.450
iot_agent_deb_armhf neutral 9.779 MiB → 10.620
iot_agent_rpm_amd64 neutral 11.231 MiB → 12.060
iot_agent_suse_amd64 neutral 11.231 MiB → 12.060

@cit-pr-commenter-54b7da
Copy link

Regression Detector

Regression Detector Results

Metrics dashboard
Target profiles
Run ID: 0d8c68a9-afed-4cff-a8c1-878ef1d75608

Baseline: 681899c
Comparison: 58f9a44
Diff

Optimization Goals: ✅ Improvement(s) detected

perf experiment goal Δ mean % Δ mean % CI trials links
tcp_syslog_to_blackhole ingress throughput +37.22 [+37.11, +37.34] 1 Logs
quality_gate_logs % cpu utilization -50.33 [-51.68, -48.98] 1 Logs bounds checks dashboard

Experiments ignored for regressions

Regressions in experiments with settings containing erratic: true are ignored.

perf experiment goal Δ mean % Δ mean % CI trials links
docker_containers_cpu % cpu utilization -2.68 [-5.68, +0.32] 1 Logs

Fine details of change detection per experiment

perf experiment goal Δ mean % Δ mean % CI trials links
tcp_syslog_to_blackhole ingress throughput +37.22 [+37.11, +37.34] 1 Logs
uds_dogstatsd_to_api_v3 ingress throughput +0.00 [-0.13, +0.13] 1 Logs
tcp_dd_logs_filter_exclude ingress throughput +0.00 [-0.09, +0.09] 1 Logs
uds_dogstatsd_to_api ingress throughput -0.02 [-0.15, +0.12] 1 Logs
ddot_metrics_sum_cumulative memory utilization -0.35 [-0.51, -0.19] 1 Logs
ddot_metrics_sum_cumulativetodelta_exporter memory utilization -0.52 [-0.75, -0.29] 1 Logs
file_to_blackhole_100ms_latency egress throughput -0.63 [-0.67, -0.59] 1 Logs
file_to_blackhole_1000ms_latency egress throughput -0.65 [-1.04, -0.27] 1 Logs
file_to_blackhole_0ms_latency egress throughput -0.66 [-1.16, -0.16] 1 Logs
file_to_blackhole_500ms_latency egress throughput -0.67 [-1.06, -0.27] 1 Logs
docker_containers_memory memory utilization -1.14 [-1.25, -1.03] 1 Logs
ddot_metrics memory utilization -1.21 [-1.44, -0.99] 1 Logs
ddot_metrics_sum_delta memory utilization -1.31 [-1.51, -1.12] 1 Logs
ddot_logs memory utilization -1.72 [-1.79, -1.65] 1 Logs
quality_gate_idle_all_features memory utilization -2.10 [-2.14, -2.06] 1 Logs bounds checks dashboard
otlp_ingest_logs memory utilization -2.10 [-2.22, -1.98] 1 Logs
quality_gate_idle memory utilization -2.55 [-2.60, -2.51] 1 Logs bounds checks dashboard
docker_containers_cpu % cpu utilization -2.68 [-5.68, +0.32] 1 Logs
file_tree memory utilization -2.76 [-2.81, -2.71] 1 Logs
uds_dogstatsd_20mb_12k_contexts_20_senders memory utilization -2.79 [-2.84, -2.73] 1 Logs
quality_gate_metrics_logs memory utilization -2.99 [-3.19, -2.78] 1 Logs bounds checks dashboard
otlp_ingest_metrics memory utilization -3.14 [-3.29, -2.99] 1 Logs
quality_gate_logs % cpu utilization -50.33 [-51.68, -48.98] 1 Logs bounds checks dashboard

Bounds Checks: ✅ Passed

perf experiment bounds_check_name replicates_passed links
docker_containers_cpu simple_check_run 10/10
docker_containers_memory memory_usage 10/10
docker_containers_memory simple_check_run 10/10
file_to_blackhole_0ms_latency lost_bytes 10/10
file_to_blackhole_0ms_latency memory_usage 10/10
file_to_blackhole_1000ms_latency lost_bytes 10/10
file_to_blackhole_1000ms_latency memory_usage 10/10
file_to_blackhole_100ms_latency lost_bytes 10/10
file_to_blackhole_100ms_latency memory_usage 10/10
file_to_blackhole_500ms_latency lost_bytes 10/10
file_to_blackhole_500ms_latency memory_usage 10/10
quality_gate_idle intake_connections 10/10 bounds checks dashboard
quality_gate_idle memory_usage 10/10 bounds checks dashboard
quality_gate_idle_all_features intake_connections 10/10 bounds checks dashboard
quality_gate_idle_all_features memory_usage 10/10 bounds checks dashboard
quality_gate_logs intake_connections 10/10 bounds checks dashboard
quality_gate_logs lost_bytes 10/10 bounds checks dashboard
quality_gate_logs memory_usage 10/10 bounds checks dashboard
quality_gate_metrics_logs cpu_usage 10/10 bounds checks dashboard
quality_gate_metrics_logs intake_connections 10/10 bounds checks dashboard
quality_gate_metrics_logs lost_bytes 10/10 bounds checks dashboard
quality_gate_metrics_logs memory_usage 10/10 bounds checks dashboard

Explanation

Confidence level: 90.00%
Effect size tolerance: |Δ mean %| ≥ 5.00%

Performance changes are noted in the perf column of each table:

  • ✅ = significantly better comparison variant performance
  • ❌ = significantly worse comparison variant performance
  • ➖ = no significant change in performance

A regression test is an A/B test of target performance in a repeatable rig, where "performance" is measured as "comparison variant minus baseline variant" for an optimization goal (e.g., ingress throughput). Due to intrinsic variability in measuring that goal, we can only estimate its mean value for each experiment; we report uncertainty in that value as a 90.00% confidence interval denoted "Δ mean % CI".

For each experiment, we decide whether a change in performance is a "regression" -- a change worth investigating further -- if all of the following criteria are true:

  1. Its estimated |Δ mean %| ≥ 5.00%, indicating the change is big enough to merit a closer look.

  2. Its 90.00% confidence interval "Δ mean % CI" does not contain zero, indicating that if our statistical model is accurate, there is at least a 90.00% chance there is a difference in performance between baseline and comparison variants.

  3. Its configuration does not mark it "erratic".

CI Pass/Fail Decision

Passed. All Quality Gates passed.

  • quality_gate_metrics_logs, bounds check memory_usage: 10/10 replicas passed. Gate passed.
  • quality_gate_metrics_logs, bounds check cpu_usage: 10/10 replicas passed. Gate passed.
  • quality_gate_metrics_logs, bounds check lost_bytes: 10/10 replicas passed. Gate passed.
  • quality_gate_metrics_logs, bounds check intake_connections: 10/10 replicas passed. Gate passed.
  • quality_gate_idle_all_features, bounds check memory_usage: 10/10 replicas passed. Gate passed.
  • quality_gate_idle_all_features, bounds check intake_connections: 10/10 replicas passed. Gate passed.
  • quality_gate_logs, bounds check lost_bytes: 10/10 replicas passed. Gate passed.
  • quality_gate_logs, bounds check intake_connections: 10/10 replicas passed. Gate passed.
  • quality_gate_logs, bounds check memory_usage: 10/10 replicas passed. Gate passed.
  • quality_gate_idle, bounds check memory_usage: 10/10 replicas passed. Gate passed.
  • quality_gate_idle, bounds check intake_connections: 10/10 replicas passed. Gate passed.

@ArmentaRoberto
Copy link
Contributor Author

ArmentaRoberto commented Jan 30, 2026

Manual QA:

Agent v7.72 was OK

2026-01-29 22:52:35 UTC | CORE | DEBUG | (pkg/aggregator/demultiplexer.go:109 in func1) | Flushing serie: {"metric":"datadog.agent.check_ready","points":[[1769727155,1]],"tags":["status:python3","check_name:custom_checkvalue","agent_version_major:7","agent_version_minor:72","agent_version_patch:0"],"host":"i-0590c9125783a10e3","type":"gauge","interval":0,"source_type_name":"System"}

Agent v7.73 regression introduced

2026-01-29 22:46:05 UTC | CORE | DEBUG | (pkg/aggregator/demultiplexer.go:109 in func1) | Flushing serie: {"metric":"datadog.agent.check_ready","points":[[1769726765,1]],"tags":["status:python3","check_name:","agent_version_major:7","agent_version_minor:73","agent_version_patch:0"],"host":"i-0590c9125783a10e3","type":"gauge","interval":0,"source_type_name":"System"}

FIX

2026-01-30 02:00:25 UTC | CORE | DEBUG | (pkg/aggregator/demultiplexer.go:109 in func1) | Flushing serie: {"metric":"datadog.agent.check_ready","points":[[1769738425,1]],"tags":["status:python3","check_name:custom_checkvalue","agent_version_major:7","agent_version_minor:77","agent_version_patch:0"],"host":"i-0590c9125783a10e3","type":"gauge","interval":0,"source_type_name":"System"}
2026-01-30 02:00:40 UTC | CORE | DEBUG | (pkg/aggregator/demultiplexer.go:109 in func1) | Flushing serie: {"metric":"datadog.agent.check_ready","points":[[1769738440,1]],"tags":["status:python3","check_name:custom_checkvalue","agent_version_major:7","agent_version_minor:77","agent_version_patch:0"],"host":"i-0590c9125783a10e3","type":"gauge","interval":0,"source_type_name":"System"}
2026-01-30 02:00:55 UTC | CORE | DEBUG | (pkg/aggregator/demultiplexer.go:109 in func1) | Flushing serie: {"metric":"datadog.agent.check_ready","points":[[1769738455,1]],"tags":["status:python3","check_name:custom_checkvalue","agent_version_major:7","agent_version_minor:77","agent_version_patch:0"],"host":"i-0590c9125783a10e3","type":"gauge","interval":0,"source_type_name":"System"}

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

qa/done QA done before merge and regressions are covered by tests short review PR is simple enough to be reviewed quickly team/agent-runtimes

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants