← Back to Pull requests

Test CI infrastructure changes on configured Dispatcher targets #25374

Closed
unknown closed this pull request without merging on Sep 28, 2026 14:53 UTC
View on GitHub
unknown unknown commented on Sep 28, 2026 13:00 UTC
Author

What does this PR do?

Adds an InfrastructureRule to Dispatcher target selection. When a pull request changes the CI plumbing every test job runs (.github/actions/setup-ddev, run-test-job, setup-test-target-scripts, tag-job), the Dispatcher now tests the targets listed in the new dispatcher.batching.test_infrastructure_targets setting, which defaults to ["disk"].

A configured target that is not testable fails planning with a PlanningError instead of being skipped silently.

Motivation

Batch jobs run these actions from the pull request checkout, but no rule matched them. A PR that only changes one of them planned zero jobs, as in this run for #25373:

Dispatcher run finished        batch_count=0 ... job_count=0 outcome=resolved

Adding them to the repository-wide rule would fan out to every target (about 857 jobs) for code that runs the same way in each job, varying only by platform and job type. A single target that goes through every branch of run-test-job validates the change at a fraction of the cost.

disk was chosen because it is the fastest target that covers all of them: unit and E2E jobs on Linux and Windows, including a real Windows E2E environment, plus minimum-base-package jobs on both platforms, which covers the Windows-only UV_LINK_MODE step. Its maximum job durations on master over the last 7 days were 98s (Linux E2E), 58s (Linux min-base), 318s (Windows E2E) and 247s (Windows min-base), with no failed jobs in the last 30 days. The alternatives each miss something:

  • krakend only runs on Linux.

  • network disables its E2E environment on Windows.

  • dns_check and tcp_check cover the same jobs but are slower and depend on external DNS and TCP endpoints.
  • Because disk is the target that exercises every branch, a change to one of these files always adds its jobs, whatever else the pull request selects. The result is the union with the other rules: changing an integration and setup-ddev runs both that integration and disk. Another selected target is not enough on its own, since it may not cover every platform and job type. For example, krakend would leave Windows untested.

    Planning against this repository with the change applied:

    .github/actions/setup-ddev/action.yml: 4 jobs
      Disk on Linux (py3.13)
      Disk on Linux (MBP) (py3.13)
      Disk on Windows (py3.13)
      Disk on Windows (MBP) (py3.13)
    
    .github/workflows/test-batch.yml: 0 jobs
    
    krakend/datadog_checks/krakend/check.py + .github/actions/setup-ddev/action.yml:
      disk: 4 jobs, krakend: 2 jobs
    

    test-batch.yml and test-dispatch.yml stay out of the rule because both are loaded from master, so a pull request cannot exercise its own changes to them.

    The repository-wide patterns are reviewed against what runs from the pull request checkout in #25375.

    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
  • Diff: 416 lines (+312 / -104) across 5 files Reviewer: HadhemiDD Review duration: 112m
    All Vouch review confidence checks passed
    Residual risk 0.27 = Change Risk (0.68) × (1 − Review Confidence (0.60)). Review depth and reviewer attention state are adequate.
    Model 1 · Change Risk (XGBoost)
    Score: 0.68 · 416 lines diff across 5 files
    0.68
    Model 2 · Review Depth (DistilBERT)
    Depth Score: 0.17 · 1 substantive comment(s)
    0.17
    Model 3 · Review Timing & Attention
    Session adequacy: 100% · Reviewer familiarity: 35%
    60%
    Bedrock Claude 3 · Risk Narration
    (disconnected)
    Groq
    Groq Risk Narration
    AWS Bedrock is currently disconnected. Generate high-confidence PR triage narration on-demand using Groq.
    Model 1 · Change Risk Attribution
    SHAP Weights
    Diff Size diff_size
    0.361
    Shallow Review Depth shallow_review_depth
    0.289
    Sensitive Paths sensitive_paths
    0.068
    Real PR Conversation Timeline
    1 comments
    "Review active on #25374"
    general weight: 0.35
    Reviewers
    Assignees
    Unassigned
    Labels
    risk: low confidence: 60.5% reviewed sensitive_module
    Vouch Risk Breakdown
    AI-powered review risk analysis
    Change Risk
    Change Risk · Model 1 (XGBoost)
    Predicted defect probability (0.00–1.00) based on diff churn, modified sensitive files, and author risk history.
    Score: 68.1% (HIGH) · Higher = larger blast radius
    68.1%
    Review Confidence
    Review Confidence · Models 2 & 3
    Scrutiny score (0.00–1.00) combining DistilBERT semantic review depth with reviewer familiarity and session dwell time.
    Score: 60.5% · Lower = rushed or shallow review
    60.5%
    Residual Risk
    Residual Risk · Core Equation
    Residual = Change × (1 − Confidence)
    Unmitigated risk surviving review. ≥ 0.65 triggers an automated re-queue to protect production.
    Score: 26.9% · Safe to merge
    26.9%