Skip to content

[ci-scan-feedback] ci-scan: add Hard Rule 10 for explicit early exit on no scannable build #7650

Description

@github-actions

Triggering signals

Proposed edits

  • .github/workflows/ci-scan.agent.md lines 80–92 (Hard Rules + Step 1 trailing sentence): adds Hard Rule 10 after Rule 9, naming the exact forbidden operations (AzDO timeline fetch, task log download, Helix query), mandating the coverage entry append, and giving the literal tally row | 0 | 0 | 0 | 1 | so the agent never needs to compute it; updates Step 1's trailing sentence from an inline restatement to a single reference apply Hard Rule 10 immediately.

Expected behavior change

On any run where Step 1 yields a selection-time skip (stale build window (>14d), no follow-up build yet, defer to next run, or no failed build in 7d), the scanner will append the skip reason to the coverage file, print | 0 | 0 | 0 | 1 | as the tally row, call noop, and stop — without fetching any AzDO timeline, downloading task logs, or querying Helix work items. Tally will correctly reflect 1 skipped-with-reason on skip-only runs. Token consumption will drop from 2.2–2.4M ET to ~250K ET on these runs.

Generated by CI Failure Scanner - Feedback (machinelearning) · ● 7.3M · ◷


Note

This was originally intended as a pull request, but the git push operation failed.

Workflow Run: View run details and download patch artifact

The patch file is available in the agent artifact in the workflow run linked above.

To create a pull request with the changes:

# Download the artifact from the workflow run
gh run download 28492716642 -n agent -D /tmp/agent-28492716642

# Create a new branch
git checkout -b ci-scan-feedback/hard-rule-10-2026-07-01-6f7c651cbf795929

# Apply the patch (--3way handles cross-repo patches where files may already exist)
git am --3way /tmp/agent-28492716642/aw-ci-scan-feedback-hard-rule-10-2026-07-01.patch

# Push the branch to origin
git push origin ci-scan-feedback/hard-rule-10-2026-07-01-6f7c651cbf795929

# Create the pull request
gh pr create --title '[ci-scan-feedback] ci-scan: add Hard Rule 10 for explicit early exit on no scannable build' --base main --head ci-scan-feedback/hard-rule-10-2026-07-01-6f7c651cbf795929 --repo dotnet/machinelearning
Show patch preview (57 of 57 lines)
From 6b11b7f1acb5f7bad1bf2c3708a8521f5be5eb10 Mon Sep 17 00:00:00 2001
From: "github-actions[bot]" <github-actions[bot]@users.noreply.github.com>
Date: Wed, 1 Jul 2026 04:15:27 +0000
Subject: [PATCH] ci-scan: add Hard Rule 10 for explicit early exit on no
 scannable build

91 consecutive ci-scan runs have skipped via the Step 1 prose ('stale build
window (>14d)') while consuming 2.2-2.4M+ effective tokens on AzDO timeline
fetches, log downloads, and Helix queries that serve no purpose once no
scannable build exists. The 'and stop' sentence in Step 1 was insufficient to
prevent continuation; agents kept fetching the AzDO timeline and walking
Steps 2-7.

Add Hard Rule 10 that elevates the no-scannable-build exit to the same
level as the issue-cap and label rules. When Step 1 determines no scannable
build exists, the scanner must:
- append the coverage entry to MachineLearning-CI.txt
- print | 0 | 0 | 0 | 1 | as the Step 7 tally (honest: 1 skipped)
- call noop and stop immediately

Update Step 1's trailing sentence to reference Hard Rule 10 directly
so the constraint is stated once, authoritatively.

Triggering signal: 13 prior ci-scan-feedback runs proposed this exact edit;
git push kept failing. Issues #7627, #7630, #7636, #7637, #7639, #7640,
#7641, #7642, #7643, #7644, #7645, #7646, #7648 are misfiled fallbacks.

Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
---
 .github/workflows/ci-scan.agent.md | 3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)

diff --git a/.github/workflows/ci-scan.agent.md b/.github/workflows/ci-scan.agent.md
index 0937c5f..c2dac53 100644
--- a/.github/workflows/ci-scan.agent.md
+++ b/.github/workflows/ci-scan.agent.md
@@ -78,6 +78,7 @@ These invariants are not delegated to the shared file. Honor them even if a shar
 7. **All state under `/tmp/gh-aw/agent/`;** each bash call is a fresh subshell.
 8. **AzDO REST is anonymous;** stay on `https://dev.azure.com/dnceng-public/public/_apis/build/...`. Follow every rule i
... (truncated)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions