-
Notifications
You must be signed in to change notification settings - Fork 0
Upgrade to .NET 10 #153
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: main
Are you sure you want to change the base?
Upgrade to .NET 10 #153
Conversation
WalkthroughUpgrades solution and projects to .NET 10, updates GitVersion to 6.5.1, bumps multiple NuGet packages, restores solution project entries, removes file-based Serilog sink from the console app, and adjusts functional tests and test project SDKs/configs. Changes
Estimated code review effort🎯 3 (Moderate) | ⏱️ ~25 minutes
Poem
Pre-merge checks and finishing touches❌ Failed checks (1 warning)
✅ Passed checks (2 passed)
✨ Finishing touches🧪 Generate unit tests (beta)
📜 Recent review detailsConfiguration used: CodeRabbit UI Review profile: CHILL Plan: Pro 📒 Files selected for processing (1)
⏰ Context from checks skipped due to timeout of 90000ms. You can increase the timeout in your CodeRabbit configuration to a maximum of 15 minutes (900000ms). (6)
🔇 Additional comments (2)
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Actionable comments posted: 2
Caution
Some comments are outside the diff and can’t be posted inline due to platform limitations.
⚠️ Outside diff range comments (1)
.github/workflows/continuous-delivery.yml (1)
64-64: Windows build still uses .NET 8 SDK - should be updated to 10.x.xThe macOS build job (line 103) was updated to use
dotnet-version: 10.x.x, but the Windows build job still uses8.x.x. Since all projects now targetnet10.0, the Windows build will fail when trying to compile against the .NET 8 SDK.Apply this diff to fix the inconsistency:
- name: Setup .NET uses: actions/setup-dotnet@v4 with: - dotnet-version: 8.x.x + dotnet-version: 10.x.x
🧹 Nitpick comments (2)
tests/Elzik.FmSync.Worker.Tests.Functional/WorkerTests.cs (1)
7-8: Unused import detected.
Microsoft.VisualStudio.TestPlatform.CommunicationUtilities(line 8) appears to be unused in this file. WhileSystem.ComponentModelis needed forWin32Exception, the TestPlatform import doesn't seem to have any references.using System.ComponentModel; -using Microsoft.VisualStudio.TestPlatform.CommunicationUtilities;src/Elzik.FmSync.Console/Elzik.FmSync.Console.csproj (1)
29-29: Remove unusedSerilog.Sinks.Filepackage reference.The package is not configured in
appSettings.json(only Console sink is used) and has no references in the codebase, making it safe to remove from the project dependencies.
📜 Review details
Configuration used: CodeRabbit UI
Review profile: CHILL
Plan: Pro
📒 Files selected for processing (16)
.github/workflows/continuous-delivery.yml(2 hunks)Elzik.FmSync.sln(2 hunks)global.json(1 hunks)src/Elzik.FmSync.Application/Elzik.FmSync.Application.csproj(2 hunks)src/Elzik.FmSync.Console/Elzik.FmSync.Console.csproj(2 hunks)src/Elzik.FmSync.Console/appSettings.json(1 hunks)src/Elzik.FmSync.Domain/Elzik.FmSync.Domain.csproj(2 hunks)src/Elzik.FmSync.Infrastructure/Elzik.FmSync.Infrastructure.csproj(2 hunks)src/Elzik.FmSync.Worker/Elzik.FmSync.Worker.csproj(3 hunks)tests/Elzik.FmSync.Application.Tests.Unit/Elzik.FmSync.Application.Tests.Unit.csproj(2 hunks)tests/Elzik.FmSync.Console.Tests.Functional/ConsoleTests.cs(0 hunks)tests/Elzik.FmSync.Console.Tests.Functional/Elzik.FmSync.Console.Tests.Functional.csproj(2 hunks)tests/Elzik.FmSync.Infrastructure.Tests.Integration/Elzik.FmSync.Infrastructure.Tests.Integration.csproj(2 hunks)tests/Elzik.FmSync.Worker.Tests.Functional/Elzik.FmSync.Worker.Tests.Functional.csproj(2 hunks)tests/Elzik.FmSync.Worker.Tests.Functional/WorkerTests.cs(3 hunks)tests/Elzik.FmSync.Worker.Tests.Functional/appSettings.json(1 hunks)
💤 Files with no reviewable changes (1)
- tests/Elzik.FmSync.Console.Tests.Functional/ConsoleTests.cs
🧰 Additional context used
🪛 GitHub Actions: Continuous Delivery
global.json
[error] 1-1: Requested .NET SDK 10.0.100 not found. global.json points to 10.0.100; installed SDKs do not include it. Install the 10.0.100 SDK or update global.json.
⏰ Context from checks skipped due to timeout of 90000ms. You can increase the timeout in your CodeRabbit configuration to a maximum of 15 minutes (900000ms). (3)
- GitHub Check: build-macos
- GitHub Check: Codacy Static Code Analysis
- GitHub Check: Analyze (csharp)
🔇 Additional comments (16)
.github/workflows/continuous-delivery.yml (2)
25-25: GitVersion.Tool update looks good.The tool version is aligned with the
GitVersion.MsBuildpackage version (6.5.1) used across project files.
103-103: macOS SDK update to 10.x.x is correct.This aligns with the target framework upgrade to
net10.0.src/Elzik.FmSync.Domain/Elzik.FmSync.Domain.csproj (1)
4-4: Package and framework updates are consistent.The target framework and package versions align with the broader .NET 10 upgrade across the solution.
Also applies to: 15-15, 19-19
src/Elzik.FmSync.Infrastructure/Elzik.FmSync.Infrastructure.csproj (1)
4-4: Infrastructure project updates are aligned with .NET 10.The target framework, GitVersion, Microsoft.Extensions.Options, and SonarAnalyzer versions are consistent with the upgrade.
Also applies to: 15-15, 19-20
tests/Elzik.FmSync.Infrastructure.Tests.Integration/Elzik.FmSync.Infrastructure.Tests.Integration.csproj (1)
4-4: Test project updates are consistent.The target framework, test SDK, and analyzer packages are properly updated. The addition of
PrivateAssetsandIncludeAssetstoxunit.analyzerscorrectly marks it as a development-only dependency.Also applies to: 37-37, 39-47
tests/Elzik.FmSync.Application.Tests.Unit/Elzik.FmSync.Application.Tests.Unit.csproj (1)
4-4: Unit test project updates are well-structured.The framework and package updates are consistent. The removal of explicit
System.Net.HttpandSystem.Text.RegularExpressionsreferences (per the AI summary) is correct since these are included in the .NET 10 runtime.Also applies to: 30-30, 36-46
src/Elzik.FmSync.Console/Elzik.FmSync.Console.csproj (1)
18-28: Package updates are consistent with .NET 10.The Microsoft.Extensions.* packages (10.0.0) and Serilog packages are properly updated to versions compatible with .NET 10.
tests/Elzik.FmSync.Worker.Tests.Functional/WorkerTests.cs (2)
339-360: Good addition of exception handling for process cleanup.The try-catch block around
KillExistingWorkerProcessesproperly handlesWin32Exceptionand provides a clear failure message when permissions are insufficient. The pattern of catching a specific exception, handling the known case, and re-throwing otherwise is correct.
111-111: Test expectation updated to match startup sequence.The change from
"Hosting started"to"A total of 1 directory watchers are running."waits for a later point in the startup sequence, ensuring the worker is fully initialized before the test proceeds.src/Elzik.FmSync.Application/Elzik.FmSync.Application.csproj (1)
4-4: Consistent .NET 10 upgrade applied.The framework and package version updates are consistent with the Worker project upgrade, maintaining alignment across the solution.
Also applies to: 15-22
Elzik.FmSync.sln (1)
28-41: Solution structure reorganized correctly.The project entries have been properly restructured with correct GUIDs and paths maintained throughout the configuration sections.
src/Elzik.FmSync.Console/appSettings.json (1)
9-13: Simplified logging configuration for console application.Removing file-based logging in favor of console-only output is appropriate for a console application, simplifying the configuration and aligning with typical console app patterns.
tests/Elzik.FmSync.Worker.Tests.Functional/appSettings.json (1)
21-21: Simplified test log path configuration.The change from a platform-specific placeholder to a relative path simplifies the test configuration and makes it more maintainable.
tests/Elzik.FmSync.Console.Tests.Functional/Elzik.FmSync.Console.Tests.Functional.csproj (1)
4-4: Test project properly upgraded to .NET 10.The framework and test tooling updates are consistent with the solution-wide upgrade. The addition of PrivateAssets and IncludeAssets attributes to xunit.analyzers improves package reference best practices.
Also applies to: 40-40, 42-42, 47-50
tests/Elzik.FmSync.Worker.Tests.Functional/Elzik.FmSync.Worker.Tests.Functional.csproj (1)
4-4: Test project upgrade mirrors Console test project pattern.The framework and package updates are consistent with the Console functional tests project, maintaining uniformity across the test suite.
Also applies to: 40-40, 42-42, 47-50
src/Elzik.FmSync.Worker/Elzik.FmSync.Worker.csproj (1)
4-4: No action required — .NET 10.0 is officially released and package versions are compatible..NET 10.0 was officially released on November 11, 2025, as a Long-Term Support (LTS) version. All referenced packages are available and compatible with .NET 10:
- GitVersion.MsBuild 6.5.0 (stable, Nov 5, 2025)
- Serilog.Extensions.Hosting 9.0.0 (stable)
- Serilog.Settings.Configuration 10.0.0 (Nov 26, 2025)
- Microsoft.Extensions.Hosting 10.0.0 (compatible with net10.0)
The target framework configuration is current and appropriate for production use.
| # Visual Studio Version 18 | ||
| VisualStudioVersion = 18.0.11205.157 d18.0 |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
🧩 Analysis chain
🌐 Web query:
Visual Studio 2025 version 18 .sln file format VisualStudioVersion specification
💡 Result:
Short answer: In VS 2025 (major version 18) the .sln file uses the same VisualStudioVersion/MinimumVisualStudioVersion lines; VisualStudioVersion should contain the full IDE build string starting with "18." (e.g. VisualStudioVersion = 18.0.) so Visual Studio can identify the creating IDE/build. The MinimumVisualStudioVersion remains the older-minimum token used for compatibility. [1][2][3]
Notes:
- VisualStudioVersion is informational and used by Visual Studio for compatibility/upgrade checks; keep it in the form "Major.Minor.Build.Revision" produced by the IDE. [1].
- Microsoft is introducing a new SLNX format but existing .sln files and their VisualStudioVersion entries remain supported; migration tools exist in the .NET CLI/Visual Studio. [1][4]
Sources:
[1] Visual Studio Blog — New, Simpler Solution File Format.
[2] .sln examples / format references (generic .sln structure).
[3] dotnet/sdk GitHub issues discussing .sln → .slnx migration.
Remove malformed suffix from VisualStudioVersion.
The VisualStudioVersion value 18.0.11205.157 d18.0 contains an invalid d18.0 suffix. Visual Studio solution files expect VisualStudioVersion in the format Major.Minor.Build.Revision (e.g., 18.0.11205.157). Change line 4 to:
VisualStudioVersion = 18.0.11205.157
🤖 Prompt for AI Agents
In Elzik.FmSync.sln around lines 3 to 4, the VisualStudioVersion value includes
a malformed suffix ("d18.0"); update the line to remove the suffix so the value
is a proper Major.Minor.Build.Revision string (e.g., change "VisualStudioVersion
= 18.0.11205.157 d18.0" to "VisualStudioVersion = 18.0.11205.157").
| { | ||
| "sdk": { | ||
| "version": "8.0.100", | ||
| "version": "10.0.100", | ||
| "rollForward": "latestMinor" | ||
| } |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
🧩 Analysis chain
🏁 Script executed:
# Find GitHub Actions workflow files
fd -t f -e yml -e yaml '.github/workflows/'Repository: elzik/fmsync
Length of output: 433
🏁 Script executed:
# Find GitHub Actions workflow files using correct syntax
fd . '.github/workflows/' -e yml -e yamlRepository: elzik/fmsync
Length of output: 97
🏁 Script executed:
# Examine the workflow file to find check-release-requirement job
cat -n '.github/workflows/continuous-delivery.yml'Repository: elzik/fmsync
Length of output: 6338
🏁 Script executed:
# Check if there are any other configuration files that specify .NET version requirements
# Look for .NET version specifications
rg -t json "dotnet|sdk" --max-count 5Repository: elzik/fmsync
Length of output: 165
🏁 Script executed:
# Check the csproj or project files to understand the target framework
fd -t f -e csproj -e fsproj | head -5 | xargs -I {} sh -c 'echo "=== {} ===" && head -15 {}'Repository: elzik/fmsync
Length of output: 2444
Add .NET SDK setup step to the check-release-requirement job.
The job runs dotnet tool install and dotnet-gitversion commands on ubuntu-latest without explicitly setting up the .NET SDK. Other jobs in the workflow use actions/setup-dotnet@v4, but this first job that runs GitVersion does not. This causes the pipeline to fail when the SDK is not available on the runner.
Add a setup step after checkout:
steps:
- uses: actions/checkout@v4
with:
fetch-depth: 0
- name: Setup .NET
uses: actions/setup-dotnet@v4
with:
dotnet-version: 10.x.x
- name: GetSemVer
...🧰 Tools
🪛 GitHub Actions: Continuous Delivery
[error] 1-1: Requested .NET SDK 10.0.100 not found. global.json points to 10.0.100; installed SDKs do not include it. Install the 10.0.100 SDK or update global.json.
🤖 Prompt for AI Agents
In global.json lines 1-5, the workflow's check-release-requirement job invokes
dotnet tool commands without ensuring the .NET SDK is installed; add a step
immediately after the actions/checkout@v4 step to run actions/setup-dotnet@v4
with with: dotnet-version: 10.x.x (or 10.0.100 to match global.json) so the SDK
is available before running dotnet tool install / dotnet-gitversion (i.e.,
insert the Setup .NET step between checkout and the GetSemVer / dotnet tool
commands).
Coverage summary from CodacySee diff coverage on Codacy
Coverage variation details
Coverage variation is the difference between the coverage for the head and common ancestor commits of the pull request branch: Diff coverage details
Diff coverage is the percentage of lines that are covered by tests out of the coverable lines that the pull request added or modified: See your quality gate settings Change summary preferences |
Summary by CodeRabbit
Chores
Changes
✏️ Tip: You can customize this high-level summary in your review settings.