Skip to content
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

[Breaking change]: Default Dotnet Tool to Run on Latest Runtime - Build time change RollForward to Major #35267

Closed
1 of 3 tasks
JL03-Yue opened this issue May 5, 2023 · 4 comments · Fixed by #35709 or #36977
Closed
1 of 3 tasks
Assignees
Labels
breaking-change Indicates a .NET Core breaking change 🏁 Release: .NET 8 Work items for the .NET 8 release 📌 seQUESTered Identifies that an issue has been imported into Quest.

Comments

@JL03-Yue
Copy link
Member

JL03-Yue commented May 5, 2023

Description

#31957

We changed the default RollForward behavior from LatestPatch to Major for dotnet tools.

Version

.NET 8 Preview 5

Previous behavior

Previously, .NET applications use a runtimeConfig to determine their runtime. The default RollForward policy is LatestPatch, which allows an application to run on any runtime of the same major/minor version that is at least as high a version as the application was built against. However, dotnet tools should be able to run on any .NET runtime equal or greater than the application's original runtime, Previously, tool authors must either explicitly set a more flexible roll-forward policy or set multitargeting. The latter has various side effects.

New behavior

We could address the mismatch in build time. The new change changes the RollForward of all tools from LatestPatch to Major. This would cause the desired behavior for all newly-built apps.

Type of breaking change

  • Binary incompatible: Existing binaries may encounter a breaking change in behavior, such as failure to load or execute, and if so, require recompilation.
  • Source incompatible: When recompiled using the new SDK or component or to target the new runtime, existing source code may require source changes to compile successfully.
  • Behavioral change: Existing binaries may behave differently at run time.

Reason for change

#30336

Dotnet tools should be able to run on any .NET runtime equal or greater than the application's original runtime. The previous RollForward policy is LatestPatch, which allows an application to run on any runtime of the same major/minor version that is at least as high a version as the application. We changed the default RollForward policy to Major to address this mismatch.

Recommended action

N/A

Feature area

SDK

Affected APIs

No response


Associated WorkItem - 97026

@JL03-Yue JL03-Yue added doc-idea breaking-change Indicates a .NET Core breaking change labels May 5, 2023
@dotnet-bot dotnet-bot added the ⌚ Not Triaged Not triaged label May 5, 2023
@gewarren gewarren added 🏁 Release: .NET 8 Work items for the .NET 8 release and removed ⌚ Not Triaged Not triaged labels May 5, 2023
@gewarren gewarren added the 🗺️ reQUEST Triggers an issue to be imported into Quest. label Jun 2, 2023
@github-actions github-actions bot added 📌 seQUESTered Identifies that an issue has been imported into Quest. and removed 🗺️ reQUEST Triggers an issue to be imported into Quest. labels Jun 3, 2023
@gewarren gewarren moved this from 🔖 Ready to 👀 In review in dotnet/docs June 2023 sprint Jun 6, 2023
@ghost ghost added the in-pr This issue will be closed (fixed) by an active pull request. label Jun 8, 2023
@github-project-automation github-project-automation bot moved this from 👀 In review to ✅ Done in dotnet/docs June 2023 sprint Jun 13, 2023
@github-project-automation github-project-automation bot moved this from 🆕 New to ✅ Done in .NET 8.0 work items Jun 13, 2023
@ghost ghost removed the in-pr This issue will be closed (fixed) by an active pull request. label Jun 13, 2023
@JL03-Yue JL03-Yue reopened this Jul 24, 2023
@github-project-automation github-project-automation bot moved this from ✅ Done to 📋 Backlog in .NET 8.0 work items Jul 24, 2023
@JL03-Yue
Copy link
Member Author

According to #34132, we decided to revert the changes as it might imply a change to our compat bar. Currently discussing alternative solutions. Is it possible to revert this breaking change documentation?

@gewarren
Copy link
Contributor

@JL03-Yue So it will only be present in Preview 5 and Preview 6? If so we should probably keep the documentation until GA and then remove it, but we can add a note saying it was reverted in Preview 7.

@JL03-Yue
Copy link
Member Author

@gewarren It'll be present in preview 7 too and reverted in rc1 according to @marcpopMSFT

@gewarren
Copy link
Contributor

Move this to the October/November sprint when those are available.

@gewarren gewarren moved this from 🔖 Ready to 🏗 In progress in dotnet/docs September 2023 sprint Sep 5, 2023
@gewarren gewarren moved this from 🏗 In progress to 👀 In review in dotnet/docs September 2023 sprint Sep 5, 2023
@ghost ghost added the in-pr This issue will be closed (fixed) by an active pull request. label Sep 5, 2023
@github-project-automation github-project-automation bot moved this from 👀 In review to ✅ Done in dotnet/docs September 2023 sprint Sep 6, 2023
@github-project-automation github-project-automation bot moved this from 📋 Backlog to ✅ Done in .NET 8.0 work items Sep 6, 2023
@ghost ghost removed the in-pr This issue will be closed (fixed) by an active pull request. label Sep 6, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
breaking-change Indicates a .NET Core breaking change 🏁 Release: .NET 8 Work items for the .NET 8 release 📌 seQUESTered Identifies that an issue has been imported into Quest.
Projects
No open projects
Status: Done
Status: Done
Status: Done
Development

Successfully merging a pull request may close this issue.

3 participants