Update dependencies and target framework to .NET 10.0#85
Merged
Conversation
Signed-off-by: Níckolas Goline <nickolas.goline+github@gmail.com>
Combined Test Results 17 files 17 suites 37s ⏱️ Results for commit e58aa0f. ♻️ This comment has been updated with latest results. |
Contributor
There was a problem hiding this comment.
Pull request overview
This PR upgrades the repository to target .NET 10.0 and updates a broad set of dependencies and CI workflows to match the new SDK baseline.
Changes:
- Retarget projects from
net9.0(andnet8.0;net9.0) tonet10.0, updating test projects and shared build props. - Update key dependencies (EF Core/Npgsql, Microsoft.Extensions.*, coverlet, LNUnit, NBitcoin, etc.) and adjust a few code paths for newer APIs.
- Update CI workflows, docs, and auxiliary tooling (Docker LND version, migration scripts) to align with .NET 10.
Reviewed changes
Copilot reviewed 54 out of 54 changed files in this pull request and generated 3 comments.
Show a summary per file
| File | Description |
|---|---|
| test/NLightning.Tests.Utils/NLightning.Tests.Utils.csproj | Retarget to net10; update LNUnit and test/project properties. |
| test/NLightning.Node.Tests/NLightning.Node.Tests.csproj | Retarget to net10; update coverlet and test SDK packages. |
| test/NLightning.Integration.Tests/NLightning.Integration.Tests.csproj | Retarget to net10; update coverlet/test SDK packages and properties. |
| test/NLightning.Infrastructure.Tests/NLightning.Infrastructure.Tests.csproj | Retarget to net10; update coverlet/test SDK packages and properties. |
| test/NLightning.Infrastructure.Serialization.Tests/NLightning.Infrastructure.Serialization.Tests.csproj | Retarget to net10; update coverlet/test SDK packages and properties. |
| test/NLightning.Infrastructure.Bitcoin.Tests/NLightning.Infrastructure.Bitcoin.Tests.csproj | Retarget to net10; update coverlet/test SDK packages and properties. |
| test/NLightning.Domain.Tests/ValueObjects/ChannelIdTests.cs | Update using directives and formatting. |
| test/NLightning.Domain.Tests/ValueObjects/ChainHashTests.cs | Update using directives. |
| test/NLightning.Domain.Tests/ValueObjects/BigSizeTests.cs | Update using directives and formatting/wrapping. |
| test/NLightning.Domain.Tests/NLightning.Domain.Tests.csproj | Retarget to net10; update coverlet/test SDK packages and properties. |
| test/NLightning.Bolt11.Tests/NLightning.Bolt11.Tests.csproj | Retarget to net10; update coverlet/test SDK packages and properties. |
| test/NLightning.Bolt11.Tests/Models/TaggedFields/MinFinalCltvExpiryTaggedFieldTests.cs | Update using directives. |
| test/NLightning.Bolt11.Tests/Models/TaggedFields/MetadataTaggedFieldTests.cs | Update using directives. |
| test/NLightning.Bolt11.Tests/Models/TaggedFields/FeaturesTaggedFieldTests.cs | Update using directives and formatting. |
| test/NLightning.Bolt11.Tests/Models/TaggedFields/ExpiryTimeTaggedFieldTests.cs | Update using directives. |
| test/NLightning.Bolt11.Tests/Models/TaggedFields/DescriptionTaggedFieldTests.cs | Update using directives and reformat InlineData payloads. |
| test/NLightning.Bolt11.Tests/Models/TaggedFieldListTests.cs | Update using directives. |
| test/NLightning.Application.Tests/NLightning.Application.Tests.csproj | Retarget to net10; update coverlet/NBitcoin; keep Microsoft.NET.Test.Sdk pinned. |
| test/Docker/custom_lnd/Dockerfile | Bump LND version used in tests. |
| test/BlazorTests/NLightning.BlazorTestApp/NLightning.BlazorTestApp.csproj | Retarget to net10; bump Blazor WASM packages and add hot reload package. |
| test/BlazorTests/NLightning.Blazor.Tests/NLightning.Blazor.Tests.csproj | Retarget to net10; bump MVC testing and Playwright packages. |
| src/NLightning.Node/NLightning.Node.csproj | Remove explicit TF/property defaults and bump Microsoft.Extensions + Npgsql/Serilog dependencies. |
| src/NLightning.Node/Helpers/AesGcmHelper.cs | Switch to Rfc2898DeriveBytes.Pbkdf2 API. |
| src/NLightning.Infrastructure/NLightning.Infrastructure.csproj | Bump libsodium and Microsoft.Extensions.* packages. |
| src/NLightning.Infrastructure.Serialization/ValueObjects/ShortChannelIdTypeSerializer.cs | Update using directives and minor formatting. |
| src/NLightning.Infrastructure.Serialization/NLightning.Infrastructure.Serialization.csproj | Remove explicit TF list and rely on shared props; formatting cleanup. |
| src/NLightning.Infrastructure.Repositories/NLightning.Infrastructure.Repositories.csproj | Remove explicit TF/property defaults and rely on shared props. |
| src/NLightning.Infrastructure.Repositories/Memory/ChannelMemoryRepository.cs | Remove some argument null checks for temporary channel methods. |
| src/NLightning.Infrastructure.Persistence/scripts/remove_migration.sh | Update EF/migration scripting and framework selection (currently broken). |
| src/NLightning.Infrastructure.Persistence/scripts/add_migration.sh | Remove explicit framework parameter from build/EF commands. |
| src/NLightning.Infrastructure.Persistence/NLightning.Infrastructure.Persistence.csproj | Bump EF Core packages to 10.0.x and remove explicit multi-targeting. |
| src/NLightning.Infrastructure.Persistence.Sqlite/NLightning.Infrastructure.Persistence.Sqlite.csproj | Bump EF Core packages to 10.0.x and remove explicit multi-targeting. |
| src/NLightning.Infrastructure.Persistence.Sqlite/Migrations/NLightningDbContextModelSnapshot.cs | Update EF Core model snapshot ProductVersion. |
| src/NLightning.Infrastructure.Persistence.SqlServer/NLightning.Infrastructure.Persistence.SqlServer.csproj | Bump EF Core packages to 10.0.x and remove explicit multi-targeting. |
| src/NLightning.Infrastructure.Persistence.Postgres/NLightning.Infrastructure.Persistence.Postgres.csproj | Bump EF Core/Npgsql provider packages to 10.0.x and remove explicit multi-targeting. |
| src/NLightning.Infrastructure.Bitcoin/Wallet/BlockchainMonitorService.cs | Simplify blocks-to-process collection to OrderedDictionary unconditionally. |
| src/NLightning.Infrastructure.Bitcoin/NLightning.Infrastructure.Bitcoin.csproj | Bump MessagePack/NBitcoin/Secp256k1/NetMQ packages. |
| src/NLightning.Domain/Protocol/Payloads/PingPayload.cs | Comment wording tweak. |
| src/NLightning.Bolt11/Models/Invoice.cs | Formatting/nullability annotation tweak for TryGetAll out variable. |
| src/NLightning.Application/NLightning.Application.csproj | Bump Microsoft.Extensions.* packages; minor project items cleanup. |
| src/Directory.Build.props | Switch to net10 as shared TF; add deterministic + test/pack defaults (problematic). |
| global.json | Pin SDK version to 10.0.0. |
| README.md | Update .NET badge/SDK link (remaining text still refers to 9.x). |
| NLightning.sln | Add src/Directory.Build.props as solution items in folders. |
| .github/workflows/pr.yml | Update CI to use .NET 10.0.x. |
| .github/workflows/pr.wasm.yml | Update CI to use .NET 10.0.x. |
| .github/workflows/pr.native.yml | Update CI to use .NET 10.0.x. |
| .github/workflows/pr.combined-report.yml | Update CI to use .NET 10.0.x. |
| .github/workflows/gh-pages.yml | Update gh-pages workflow to setup-dotnet@v4 and .NET 10.0.x; formatting cleanup. |
| .github/workflows/dotnet.yml | Update CI to use .NET 10.0.x. |
| .github/workflows/dotnet.wasm.yml | Update CI to use .NET 10.0.x. |
| .github/workflows/dotnet.native.yml | Update CI to use .NET 10.0.x. |
| .github/workflows/combined-report.yml | Update CI to use .NET 10.0.x. |
| .docfx/docs/quickstart/quickstart.md | Update quickstart prerequisites to .NET 10.0. |
Comments suppressed due to low confidence (2)
src/NLightning.Infrastructure.Repositories/Memory/ChannelMemoryRepository.cs:83
AddChannel/UpdateChannelstill validatechannelwithThrowIfNull, but the temporary-channel methods no longer validate thechannelargument at all. Sincechannelis a reference type, passing null will now result in a NullReferenceException when accessingchannel.ChannelId. Keep the null guard forchannelhere for consistent and clearer argument validation (null checks forCompactPubKey/ChannelIdaren’t needed since they’re structs).
public void AddTemporaryChannel(CompactPubKey compactPubKey, ChannelModel channel)
{
if (!_temporaryChannels.TryAdd((compactPubKey, channel.ChannelId), channel))
throw new InvalidOperationException(
$"Temporary channel with Id {channel.ChannelId} for CompactPubKey {compactPubKey} already exists.");
README.md:62
- README prerequisites text is inconsistent with the .NET 10 update: it still says “any later 9.x version” and the following paragraph still describes
global.jsonpinning to 9.0.0 / only supporting 9.x. Update this section to match the newglobal.json(10.0.0) and supported SDK range (10.x).
- [.NET 10.0 SDK](https://dotnet.microsoft.com/download/dotnet/10.0) or any later 9.x version
- Git (for cloning the repository)
This project uses a global.json file to pin the .NET SDK to version 9.0.0, but with rollForward:
"latestMinor" it will accept any newer 9.x release (e.g., 9.1.x, 9.2.x).
You must have .NET SDK 9.0.0 or later within the 9.x line installed.
SDK versions outside the 9.x line (e.g., 8.x or 10.x) are not supported.
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
You can also share your feedback on Copilot code review. Take the survey.
test/NLightning.Application.Tests/NLightning.Application.Tests.csproj
Outdated
Show resolved
Hide resolved
src/NLightning.Infrastructure.Persistence/scripts/remove_migration.sh
Outdated
Show resolved
Hide resolved
upgrade xunit; fix test warnings; Signed-off-by: Níckolas Goline <nickolas.goline+github@gmail.com>
Signed-off-by: Níckolas Goline <nickolas.goline+github@gmail.com>
Signed-off-by: Níckolas Goline <nickolas.goline+github@gmail.com>
|
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
No description provided.