Skip to content

The Changes job fails open, misses renames, and does not list tools/Shared or .config/dotnet-tools.json #70

Open

Description

@CaffeinatedCoder

Problem

The changes job in dotnet.yml (added in 44b3ef0) decides whether a PR runs Pack and Consumer smoke test, two required checks. It can answer "nothing to pack" when the PR does change a package, and nothing reports that. There are three ways.

1. It fails open. The workflow comment says a failed git diff "fails the job rather than answering false, so a broken diff can never skip the pack". The opposite happens:

  • Changes is not a required check.
  • When it fails, Pack and Consumer are skipped because a job they need failed.
  • GitHub reports a skipped job as Success on a required check ("A job that is skipped will report its status as "Success". It will not prevent a pull request from merging, even if it is a required check").

So Test (ubuntu-latest) and Labels and issue link decide the merge alone. This follows from GitHub's documented rule; it has not been reproduced on a live PR.

2. It cannot see a rename's source. git diff --name-only without --no-renames lists only the new path of a renamed file. Moving a file from src/ to spikes/ or docs/ reports just the new path, so the job answers product=false. Checked locally with git 2.54: git mv src/A.cs docs/A.cs lists docs/A.cs alone, while --no-renames lists both paths.

3. Two inputs are missing from its list.

  • tools/Shared/*.cs is compiled into the smoke test tool through tools/Directory.Build.props (<Compile Include="$(MSBuildThisFileDirectory)Shared/*.cs" />), but only tools/ConsumerSmokeTest/* is listed.
  • .config/dotnet-tools.json pins the CycloneDX that Pack's SBOM step runs, and it is not listed either.

A change to either skips Pack and Consumer on the PR. The first run of the changed code is the push to the release branch.

Change

  • git diff --name-only --no-renames -z.
  • The deciding list comes from the project graph: the smoke tool's and the shipping projects' MSBuild inputs, including linked and imported files, plus .config/dotnet-tools.json. Any path the list does not recognise selects the pack, rather than skipping it.
  • A job that always runs requires Changes to have succeeded (CI: a gate job over every job, and which legs it requires #71). Until then, make Changes a required check.
  • Seeds, each shown to fail:
    • a rename out of src/
    • an edit to tools/Shared/SharedFile.cs
    • an edit to .config/dotnet-tools.json
    • Changes exiting 1 on a PR

Done when

All four seeds fail the PR's required checks, rather than skipping Pack and Consumer.

Activity

  1. added this to the 2.3.0 milestone on Oct 20, 2026
  2. added
    bugSomething isn't working
    silentCompiles or answers and does less than it appears to
    severity/mediumInconsistency or failure in a narrow scenario
    area/releaseVersioning, changelogs, packaging and release wiring
    area/toolingThe repository's tools: prober, verdict, guard, docs-query, smoke test
    on Oct 20, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    area/releaseVersioning, changelogs, packaging and release wiringarea/toolingThe repository's tools: prober, verdict, guard, docs-query, smoke testbugSomething isn't workingseverity/mediumInconsistency or failure in a narrow scenariosilentCompiles or answers and does less than it appears to

    Projects

    No projects

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions