Skip to content

Add test-debug label to run PR tests with verbose pytest logging - #24436

Merged
vitkyrka merged 1 commit into
masterfrom
vitkyrka/test-debug
Jul 20, 2026
Merged

Add test-debug label to run PR tests with verbose pytest logging#24436
vitkyrka merged 1 commit into
masterfrom
vitkyrka/test-debug

Conversation

@vitkyrka

@vitkyrka vitkyrka commented Jul 8, 2026

Copy link
Copy Markdown
Contributor

What does this PR do?

Adds a conditional to the top-level pr.yml workflow: when a PR has the test-debug label, its tests run with -rP --log-level=DEBUG passed to pytest via the existing pytest-args input.

Motivation

Some servers (e.g. kong 1.5.0) only provide Docker images for amd64, so their E2E tests can't be run locally on non-amd64 dev machines to inspect debug output such as discovery candidate probing (assert_all_discovery_candidates_stable). With this change, adding the test-debug label to a PR surfaces that debug output directly in the CI job log instead, without needing any local run. By requiring a separate label, we don't pollute the logs for the common case.

This was validated against the kong-discovery branch (PR #24318): the label correctly threaded -rP --log-level=DEBUG through to the pytest invocation, and test_e2e_discovery_all_candidates's captured debug output appeared in the CI job log even though the test passed.

Review checklist (to be filled by reviewers)

  • Feature or bugfix MUST have appropriate tests (unit, integration, e2e)
  • Add qa/required if this PR needs QA validation, or qa/skip-qa if it does not. Exactly one of the two is required.
  • If you need to backport this PR to another branch, you can add the backport/<branch-name> label to the PR and it will automatically open a backport PR once this one is merged

Some integrations (e.g. kong) only build/run on amd64, so their E2E tests
can't be run locally on non-amd64 dev machines to inspect debug output such
as discovery candidate probing. Setting the "test-debug" label on a PR now
passes -rP --log-level=DEBUG to pytest via the existing pytest-args input,
surfacing that output in the CI job log instead.

Environment: Datadog workspace

Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
@vitkyrka
vitkyrka force-pushed the vitkyrka/test-debug branch from 48f6179 to c8fe486 Compare July 8, 2026 14:54

vitkyrka commented Jul 8, 2026

Copy link
Copy Markdown
Contributor Author

@codex review

@chatgpt-codex-connector chatgpt-codex-connector Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

💡 Codex Review

Here are some automated review suggestions for this pull request.

Reviewed commit: c8fe486942

ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".

Comment thread .github/workflows/pr.yml
@vitkyrka
vitkyrka marked this pull request as ready for review July 8, 2026 15:01
@vitkyrka
vitkyrka requested a review from a team as a code owner July 8, 2026 15:01
@dd-octo-sts

dd-octo-sts Bot commented Jul 20, 2026

Copy link
Copy Markdown
Contributor

Validation Report

All 21 validations passed.

Show details
Validation Description Status
agent-reqs Verify check versions match the Agent requirements file
ci Validate CI configuration and code coverage settings
codeowners Validate every integration has a CODEOWNERS entry
config Validate default configuration files against spec.yaml
dep Verify dependency pins are consistent and Agent-compatible
http Validate integrations use the HTTP wrapper correctly
imports Validate check imports do not use deprecated modules
integration-style Validate check code style conventions
jmx-metrics Validate JMX metrics definition files and config
labeler Validate PR labeler config matches integration directories
legacy-signature Validate no integration uses the legacy Agent check signature
license-headers Validate Python files have proper license headers
licenses Validate third-party license attribution list
metadata Validate metadata.csv metric definitions
models Validate configuration data models match spec.yaml
openmetrics Validate OpenMetrics integrations disable the metric limit
package Validate Python package metadata and naming
qa-label Validate the pull request declares whether it needs QA for the next Agent release
readmes Validate README files have required sections
saved-views Validate saved view JSON file structure and fields
version Validate version consistency between package and changelog

View full run

@vitkyrka
vitkyrka added this pull request to the merge queue Jul 20, 2026
Merged via the queue into master with commit 2042232 Jul 20, 2026
47 checks passed
@vitkyrka
vitkyrka deleted the vitkyrka/test-debug branch July 20, 2026 08:15
@dd-octo-sts dd-octo-sts Bot added this to the 7.83.0 milestone Jul 20, 2026
github-actions Bot pushed a commit to ConnectionMaster/integrations-core that referenced this pull request Jul 20, 2026
…aDog#24436)

Some integrations (e.g. kong) only build/run on amd64, so their E2E tests
can't be run locally on non-amd64 dev machines to inspect debug output such
as discovery candidate probing. Setting the "test-debug" label on a PR now
passes -rP --log-level=DEBUG to pytest via the existing pytest-args input,
surfacing that output in the CI job log instead.

Environment: Datadog workspace

Co-authored-by: Claude Sonnet 5 <noreply@anthropic.com> 2042232
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants