Skip to content

Split automated dependency updates into OpenTelemetry, Azure, and other PRs - #22432

Merged
Adam Ratzman (adamint) merged 7 commits into
mainfrom
eerhardt-split-dependency-update-prs
Nov 25, 2026
Merged

Adam Ratzman (adamint) merged 7 commits into
mainfrom
eerhardt-split-dependency-update-prs

Conversation

@eerhardt

@eerhardt Eric Erhardt (eerhardt) commented Nov 19, 2026 •

Copy link
Copy Markdown
Member

Description

The weekly Update Dependencies workflow opens a single PR with every external package update. One package that can't be updated yet (for example, because it isn't mirrored to the internal feeds) blocks all the others, so the PR tends to sit open for months (#20281 has been open since September).

This change splits the workflow into one PR per package group:

Group dotnet-outdated filters Branch
OpenTelemetry --include OpenTelemetry update-dependencies-opentelemetry
Azure --include Azure --exclude OpenTelemetry update-dependencies-azure
other (catch-all) --exclude OpenTelemetry --exclude Azure update-dependencies (the existing branch)

The filters give every package exactly one group: Azure.Monitor.OpenTelemetry.Exporter goes with OpenTelemetry. Only the catch-all job opens an issue when no PR is created, because the smaller groups often have nothing to update.

It also stops dotnet-outdated from bypassing the $(...Version) properties in eng/Versions.props, which the project templates, Blazor scripts and MAUI playground read. Depending on the layout, dotnet-outdated 4.9.0 (now pinned) either inlines the new version into Directory.Packages.props, or adds an overriding property there and can repoint a reference to a different property. A new step runs the file-based C# app .github/workflows/update-dependencies-version-properties.cs. It restores every original reference (Include and Update elements), removes the added overriding properties, and moves the new version into eng/Versions.props for properties used only by the external dependencies ItemGroup. Then it stages both files, so a run where every update is rejected leaves no stale index behind. Other properties keep their version, with a workflow warning:

  • packages Darc manages through eng/Version.Details.xml
  • the .NET 10 servicing pins outside the external dependencies ItemGroup
  • properties not defined in eng/Versions.props
  • packages that share a property but resolved to different versions

Validation:

  • dotnet test --project tests/Infrastructure.Tests/Infrastructure.Tests.csproj --no-launch-profile -- --filter-class "*.UpdateDependenciesVersionPropertiesTests" --filter-not-trait "quarantined=true" --filter-not-trait "outerloop=true": passed (4 tests).
  • actionlint -shellcheck= -pyflakes= .github/workflows/update-dependencies.yml (v1.7.12): passed.
  • Ran the script against the real Directory.Packages.props, eng/Versions.props and eng/Version.Details.xml with simulated inlined versions. The OpenTelemetry and Azure Monitor properties were updated in eng/Versions.props. The Darc-managed Microsoft.DotNet.Build.Tasks.Archives, the SystemTextJsonNet10Version pin and MicrosoftSignedWixVersion were restored unchanged.
  • Ran dotnet-outdated 4.9.0 on a temporary copy of this repo with two OpenTelemetry properties lowered to 1.18.0, then the cleanup step and the app. The final diff only bumped those two properties in eng/Versions.props; Directory.Packages.props was unchanged.
  • The workflow itself hasn't run yet. It can be started manually with workflow_dispatch after merge.

Fixes # (issue)

Checklist

  • Is this feature complete?
    • Yes. Ready to ship.
    • No. Follow-up changes expected.
  • Are you including unit tests for the changes and scenario tests if relevant?
    • Yes
    • No
  • Did you add public API?
    • Yes
      • If yes, did you have an API Review for it?
        • Yes
        • No
      • Did you add <remarks /> and <code /> elements on your triple slash comments?
        • Yes
        • No
    • No
  • Does the change make any security assumptions or guarantees?
    • Yes
      • If yes, have you done a threat model and had a security review?
        • Yes
        • No
    • No

…er PRs

The update-dependencies workflow now runs one matrix job per package group, each with its own branch and PR, so a package that can't be updated yet doesn't block the others. A new script restores the $(...Version) references that dotnet-outdated inlines and moves the new versions into eng/Versions.props.

Co-authored-by: Copilot App <[email protected]>
@github-actions

Copy link
Copy Markdown
Contributor

🚀 Dogfood this PR with:

⚠️ WARNING: Do not do this without first carefully reviewing the code of this PR to satisfy yourself it is safe.

curl -fsSL https://raw.githubusercontent.com/microsoft/aspire/main/eng/scripts/get-aspire-cli-pr.sh | bash -s -- 22432

Or

  • Run remotely in PowerShell:
iex "& { $(irm https://raw.githubusercontent.com/microsoft/aspire/main/eng/scripts/get-aspire-cli-pr.ps1) } 22432"

@github-actions github-actions Bot added the area-codeflow for labeling automated codeflow. intentionally a different color! label Nov 19, 2026
@aspire-repo-bot
aspire-repo-bot Bot requested a balanced review from Copilot November 19, 2026 17:30
@github-actions

This comment has been minimized.

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

🟡 Changes recommended

The dependency updater can retain local overrides that bypass protected version pins, skip Update references, and discard property-file upgrades, breaking intended version control and future updates.

1 open issue
What changed in this PR

Splits Aspire’s weekly dependency updates into separate PRs so a blocked package group does not hold up unrelated updates.

Changes:

  • Creates OpenTelemetry, Azure, and catch-all update jobs with separate branches; only the catch-all reports a missing PR.
  • Adds version-property restoration intended to preserve shared version references and respect dependency ownership.
  • Adds behavioral tests for restoration and command-line execution.
File Description
tests/​Infrastructure.Tests/​WorkflowScripts/​UpdateDependenciesVersionPropertiesTests.cs Tests version transfers, protected properties, conflicts, and file rewriting.
tests/​Infrastructure.Tests/​WorkflowScripts/​update-dependencies-version-properties.harness.js Invokes the production restoration function with test inputs.
.github/​workflows/​update-dependencies.yml Splits updates by package group and invokes restoration.
.github/​workflows/​update-dependencies-version-properties.js Restores property references and transfers eligible versions into eng/Versions.props.

Review effort: Balanced

@github-actions

This comment has been minimized.

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

🟡 Changes recommended

The workflow can silently lose property-backed dependency updates, fail on stale staged changes when all updates are rejected, and leave PackageVersion Update references unrestored.

4 open issues

Review effort: Balanced

Pin dotnet-outdated to 4.9.0, move properties it adds to Directory.Packages.props into eng/Versions.props, restore repointed and Update references, and stage the final files so a run with every update rejected doesn't leave a stale index.

Co-authored-by: Copilot App <[email protected]>
@github-actions

Copy link
Copy Markdown
Contributor

Tests selector

1 / 101 PR test projects · 0 PR jobs, from 3 changed files.

Selected PR test projects (1 / 101)

Infrastructure.Tests

Selected PR jobs (0)

none


How these were chosen — grouped by what changed

📄 .github/workflows/update-dependencies-version-properties.cs (changed)
→ 1 directly: Infrastructure.Tests

📄 .github/workflows/update-dependencies.yml (changed)
→ 1 directly: Infrastructure.Tests

🧪 tests/Infrastructure.Tests/WorkflowScripts/UpdateDependenciesVersionPropertiesTests.cs (changed test)
→ 1 directly: Infrastructure.Tests

Job reasons

none


Selection computed for commit a677888.

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

🟢 Approval recommended

No active review issues were identified in the dependency-update grouping and shared version-property changes.

No open issues 🎉

4 resolved since last review

Review effort: Balanced

@adamint
Adam Ratzman (adamint) merged commit 36bcf39 into main Nov 25, 2026
49 checks passed
@microsoft-github-policy-service microsoft-github-policy-service Bot added this to the 17.1 milestone Nov 25, 2026
@aspire-repo-bot

Copy link
Copy Markdown
Contributor

✅ No documentation update needed.

Branch: proven false positive (docs_optional-equivalent → build_or_ci_only).

Triggered signals: pr_body_has_cli_flag_mention (evidence: PR body table mentions --include OpenTelemetry, which are dotnet-outdated flags in an internal GitHub Actions workflow, not Aspire CLI flags). Advisory only_test_or_build_changes is true.

All 3 changed files match .github/** or tests/** (.github/workflows/update-dependencies.yml, .github/workflows/update-dependencies-version-properties.cs, tests/Infrastructure.Tests/WorkflowScripts/UpdateDependenciesVersionPropertiesTests.cs). No user-facing change.

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

Labels

area-codeflow for labeling automated codeflow. intentionally a different color!

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants