-
Notifications
You must be signed in to change notification settings - Fork 1.2k
Description
Describe the bug
NETSDK1138 is currently not generated for .NET 6 when using the .NET 9 SDK. It went EOL when .NET 9 was released. https://learn.microsoft.com/de-de/dotnet/core/tools/sdk-errors/netsdk1138 is showing that .NET 6 is considered EOL, so I would have expected to receive this warning.
sdk/src/Tasks/Microsoft.NET.Build.Tasks/targets/Microsoft.NET.EolTargetFrameworks.targets
Lines 23 to 28 in 9142933
| <ItemGroup> | |
| <_EolNetCoreTargetFrameworkVersions Include="1.0;1.1;2.0;2.1;2.2;3.0;3.1;5.0;7.0" /> | |
| </ItemGroup> | |
| <PropertyGroup> | |
| <_MinimumNonEolSupportedNetCoreTargetFramework>net6.0</_MinimumNonEolSupportedNetCoreTargetFramework> | |
| </PropertyGroup> |
sdk/test/Microsoft.NET.Build.Tests/GivenThatWeWantToTargetEolFrameworks.cs
Lines 12 to 19 in 9142933
| [Theory] | |
| [InlineData("netcoreapp1.0")] | |
| [InlineData("netcoreapp2.1")] | |
| [InlineData("netcoreapp3.0")] | |
| [InlineData("netcoreapp3.1")] | |
| [InlineData("net5.0")] | |
| [InlineData("net7.0")] | |
| public void It_warns_that_framework_is_out_of_support(string targetFrameworks) |
Please check if this is intentional. It was also not changed for .NET 10 Preview 1 so far.
To Reproduce
- Create a new console application
- Change target framework to
net6.0 - Compile
Exceptions (if any)
None, would have expected to see NETSDK1138 nowadays. It's currently only blocked explicitly for net6.0-android through https://github.com/dotnet/android/blob/main/src/Xamarin.Android.Build.Tasks/Microsoft.Android.Sdk/Sdk/Eol.targets
Or is this expected to happen at a later point in time? I see in the history that .NET 7 was added in September 2024 when it went EOL in May 2024.