-
Notifications
You must be signed in to change notification settings - Fork 5.9k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
7 changed files
with
133 additions
and
15 deletions.
There are no files selected for viewing
This file contains 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
This file contains 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
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,60 @@ | ||
--- | ||
title: "Breaking change: Warning emitted when targeting net7.0" | ||
description: Learn about the breaking change in the .NET SDK where a warning is issued for apps that target net7.0, which is out of support. | ||
ms.date: 11/6/2024 | ||
--- | ||
|
||
# Warning emitted when targeting net7.0 | ||
|
||
Starting with the November 2024 releases of the .NET 8 and 9 SDKs, warning [NETSDK1138](../../../tools/sdk-errors/netsdk1138.md) is issued if your app targets `net7.0`. .NET 7 is now out of support. | ||
|
||
When a version of .NET goes out of support, it's marked as such in Visual Studio the following month. The .NET SDK waits 6 months before adding a warning. | ||
|
||
This change applies to .NET 8.0.111, 8.0.307, 8.0.404, and 9.0.100. | ||
|
||
## Version introduced | ||
|
||
.NET 9 GA | ||
|
||
## Previous behavior | ||
|
||
Previously, apps could target `net7.0` without a warning, even though it was out of support. | ||
|
||
## New behavior | ||
|
||
Starting in .NET 9 and the other [affected versions](#version-introduced), the following warning is issued at compile time for apps that target `net7.0`: | ||
|
||
> warning NETSDK1138: The target framework 'net7.0' is out of support | ||
## Type of breaking change | ||
|
||
This change can affect [source compatibility](../../categories.md#source-compatibility). | ||
|
||
## Reason for change | ||
|
||
This is a planned change to ensure that customers are aware that they're targeting an unsupported framework version. | ||
|
||
## Recommended action | ||
|
||
Upgrade your app to target `net8.0`. | ||
|
||
If you must continue targeting `net7.0`, you can set the MSBuild property `CheckEolTargetFramework` to `false`. You can set it in the project file or by passing `/p:CheckEolTargetFramework=false` to a .NET CLI command such as `dotnet build`. | ||
|
||
Example *.csproj* or *.vbproj* file: | ||
|
||
```xml | ||
<Project Sdk="Microsoft.NET.Sdk"> | ||
<PropertyGroup> | ||
... | ||
<CheckEolTargetFramework>false</CheckEolTargetFramework> | ||
</PropertyGroup> | ||
</Project> | ||
``` | ||
|
||
## Affected APIs | ||
|
||
None. | ||
|
||
## See also | ||
|
||
- [NETSDK1138: The target framework is out of support](../../../tools/sdk-errors/netsdk1138.md) |
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,47 @@ | ||
--- | ||
title: "Breaking change: Version requirements for .NET 9 SDK" | ||
description: Learn about the breaking change in the .NET 9 SDK where specific versions of Visual Studio and MSBuild are required. | ||
ms.date: 11/06/2024 | ||
--- | ||
# Version requirements for .NET 9 SDK | ||
|
||
Per the [published support rules](../../../porting/versioning-sdk-msbuild-vs.md#targeting-and-support-rules), the minimum Visual Studio and MSBuild version for each new major release is updated with a one quarter delay. For the .NET 9 release: | ||
|
||
- 9.0.100 requires version 17.11 to target `net8.0` and earlier frameworks. | ||
- 9.0.100 requires version 17.12 or later to target `net9.0`. | ||
|
||
## Version introduced | ||
|
||
.NET 9 GA | ||
|
||
## Previous behavior | ||
|
||
Previously, you could load .NET 9.0.100 on earlier Visual Studio versions. In addition, there was no warning when targeting `net9.0` in Visual Studio version 17.11. | ||
|
||
## New behavior | ||
|
||
- .NET 9.0.100 won't load in Visual Studio version 17.10 or earlier. | ||
- Visual Studio version 17.11 doesn't make `net9.0` available in the project properties. | ||
- .NET 9.0.100 warns when targeting `net9.0` and using Visual Studio version 17.11: | ||
|
||
> NETSDK1223: Targeting .NET 9.0 or higher in Visual Studio 2022 17.11 is not supported. | ||
## Type of breaking change | ||
|
||
This change can affect [source compatibility](../../categories.md#source-compatibility). | ||
|
||
## Reason for change | ||
|
||
This is part of the standard support policy for the SDK as not all prior versions of Visual Studio and MSBuild can be supported. | ||
|
||
## Recommended action | ||
|
||
Upgrade your Visual Studio version to the required version. | ||
|
||
## Affected APIs | ||
|
||
N/A | ||
|
||
## See also | ||
|
||
- [Targeting and support rules](../../../porting/versioning-sdk-msbuild-vs.md#targeting-and-support-rules) |
This file contains 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
This file contains 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
This file contains 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