Skip to content

Conversation

Copy link
Contributor

Copilot AI commented Dec 12, 2025

  1. What triggered this change? (PBI link, Email Subject, conversation + reason, etc)

Review feedback from @jernejk on PR #1472: #1472 (comment)

  1. What was changed?

MediatR package version changed from fixed 12.2.0 to explicit version range [12.*,13.0) in:

  • src/Domain/SSW.Rewards.Domain.csproj
  • src/Application/SSW.Rewards.Application.csproj

The explicit version range syntax [12.*,13.0) specifies:

  • Minimum version: 12.* (inclusive)
  • Maximum version: 13.0 (exclusive)

This allows automatic patch updates within version 12.x (currently resolves to 12.5.0) while explicitly preventing breaking changes from version 13.0 and above.

  1. Did you do pair or mob programming?

Worked with @jernejk


💬 We'd love your input! Share your thoughts on Copilot coding agent in our 2 minute survey.

Copilot AI changed the title [WIP] Update MediatR to version 12 based on feedback Update MediatR to version 12.* for flexible patch updates Dec 12, 2025
Copilot AI requested a review from jernejk December 12, 2025 01:09
<PackageReference Include="FluentValidation.DependencyInjectionExtensions" Version="12.1.1" />
<PackageReference Include="Hangfire.Core" Version="1.8.20" />
<PackageReference Include="MediatR" Version="12.2.0" />
<PackageReference Include="MediatR" Version="12.*" />
Copy link
Member

Choose a reason for hiding this comment

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

@copilot, shouldn't it be something like Version="[12.*,13.0)"

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Updated to use explicit version range [12.*,13.0) for both projects. This ensures MediatR stays within version 12.x and explicitly excludes version 13.0 and above. Commit: 5d9eec9

Copilot AI changed the title Update MediatR to version 12.* for flexible patch updates Update MediatR to explicit version range [12.*,13.0) for flexible patch updates Dec 12, 2025
Copilot AI requested a review from jernejk December 12, 2025 03:47
@jernejk jernejk marked this pull request as ready for review December 12, 2025 05:37
Copilot AI review requested due to automatic review settings December 12, 2025 05:37
@jernejk jernejk merged commit da05921 into dotnet-10 Dec 12, 2025
@jernejk jernejk deleted the copilot/sub-pr-1472 branch December 12, 2025 05:38
Copy link
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

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

Pull request overview

This PR attempts to update the MediatR package version from a fixed 12.2.0 to a flexible version range that allows automatic patch updates within version 12.x while preventing breaking changes from version 13.0. The change was triggered by review feedback on PR #1472, with the goal of enabling more flexible dependency management.

Key Changes:

  • Modified MediatR version specification in Domain and Application projects
  • Intended to allow patch updates while preventing major version upgrades

Reviewed changes

Copilot reviewed 2 out of 2 changed files in this pull request and generated 2 comments.

File Description
src/Domain/SSW.Rewards.Domain.csproj Updated MediatR version to use version range syntax
src/Application/SSW.Rewards.Application.csproj Updated MediatR version to use version range syntax

⚠️ Critical Issue Found: The version range syntax [12.*,13.0) used in this PR is invalid. NuGet does not support wildcards inside explicit version range brackets, which will cause build errors or unexpected behavior. Please see the comments for the correct syntax to use.


<ItemGroup>
<PackageReference Include="MediatR" Version="12.2.0" />
<PackageReference Include="MediatR" Version="[12.*,13.0)" />
Copy link

Copilot AI Dec 12, 2025

Choose a reason for hiding this comment

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

The version range syntax [12.*,13.0) is invalid. NuGet does not support wildcards (*) inside explicit version range brackets. This will cause build errors or unexpected behavior.

Use one of these valid alternatives:

  • [12.0,13.0) - allows any version from 12.0 (inclusive) to 13.0 (exclusive)
  • 12.* - allows any 12.x patch version (simpler but less explicit about upper bound)

The first option is recommended as it explicitly prevents breaking changes from version 13.0 while allowing all 12.x updates.

Suggested change
<PackageReference Include="MediatR" Version="[12.*,13.0)" />
<PackageReference Include="MediatR" Version="[12.0,13.0)" />

Copilot uses AI. Check for mistakes.
<PackageReference Include="FluentValidation.DependencyInjectionExtensions" Version="12.1.1" />
<PackageReference Include="Hangfire.Core" Version="1.8.20" />
<PackageReference Include="MediatR" Version="12.2.0" />
<PackageReference Include="MediatR" Version="[12.*,13.0)" />
Copy link

Copilot AI Dec 12, 2025

Choose a reason for hiding this comment

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

The version range syntax [12.*,13.0) is invalid. NuGet does not support wildcards (*) inside explicit version range brackets. This will cause build errors or unexpected behavior.

Use one of these valid alternatives:

  • [12.0,13.0) - allows any version from 12.0 (inclusive) to 13.0 (exclusive)
  • 12.* - allows any 12.x patch version (simpler but less explicit about upper bound)

The first option is recommended as it explicitly prevents breaking changes from version 13.0 while allowing all 12.x updates.

Suggested change
<PackageReference Include="MediatR" Version="[12.*,13.0)" />
<PackageReference Include="MediatR" Version="[12.0,13.0)" />

Copilot uses AI. Check for mistakes.
zacharykeeping added a commit that referenced this pull request Dec 14, 2025
* Upgrade to .NET 10

* Bump versions

* Update packages

* Update .github/chatmodes/gh-actions.chatmode.md

Co-authored-by: Copilot <[email protected]>

* Update AGENTS.md

Co-authored-by: Copilot <[email protected]>

* Update packages

* Update packages

* Fix background

* Fix tests

* Bump packages

* Updated AGENTS.md C# version

* Update .chatmodes with C# 14 version

* Update src/WebAPI/Dockerfile

Co-authored-by: Copilot <[email protected]>

* Update src/AdminUI/Dockerfile

Co-authored-by: Copilot <[email protected]>

* Update dockerfile

* Update MediatR to explicit version range [12.*,13.0) for flexible patch updates (#1474)

* Initial plan

* Update MediatR version to 12.* in Domain and Application projects

Co-authored-by: jernejk <[email protected]>

* Use explicit version range [12.*,13.0) for MediatR

Co-authored-by: jernejk <[email protected]>

---------

Co-authored-by: copilot-swe-agent[bot] <[email protected]>
Co-authored-by: jernejk <[email protected]>

---------

Co-authored-by: Copilot <[email protected]>
Co-authored-by: Jernej Kavka (JK) [SSW • Microsoft MVP] <[email protected]>
Co-authored-by: Copilot <[email protected]>
Co-authored-by: jernejk <[email protected]>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants