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

Adhere to the package support policy by building and packaging supported frameworks only #53282

Closed
ViktorHofer opened this issue May 26, 2021 · 5 comments
Assignees
Labels
area-Infrastructure-libraries breaking-change Issue or PR that represents a breaking API or functional change over a prerelease. needs-breaking-change-doc-created Breaking changes need an issue opened with https://github.com/dotnet/docs/issues/new?template=dotnet
Milestone

Comments

@ViktorHofer
Copy link
Member

ViktorHofer commented May 26, 2021

Continuation of #47530

The runtime repository currently produces 102 packages from libraries of which 25 of those contain assets which will be unsupported when we release .NET 6 in November 2021. The list of unsupported assets includes netstandard1.x assets as those apply to unsupported application frameworks only as in any case where a netstandard1.x asset is present, a netstandard2.0 (and in most cases a net461 asset) exists as well which allows to run on .NET Framework 4.6.1 or .NET Core 3.1 and above.

The reasons for trimming out unsupported assets are:

  • Simplified build graph and reduced build times
  • Less restore size as the NS1.x dependency graph doesn't need to be restored
  • Package validation costs
  • Fat packages
  • Maintenance of code bases which are not tested anymore.

Based on these disadvantages we will remove the remaining unsupported assets from packages in dotnet/runtime.

List of packages grouped by TargetFrameworkIdentifier

NETStandard,Version=1.x -> .NETStandard,Version=2.0

  • Microsoft.Extensions.HostFactoryResolver.Sources
  • System.Collections.Immutable
  • System.Diagnostics.DiagnosticSource
  • System.IO.Packaging
  • System.Numerics.Tensors
  • System.Reflection.Context
  • System.Reflection.Metadata
  • System.Runtime.CompilerServices.Unsafe
  • System.Threading.Channels
  • System.Threading.Tasks.Dataflow

PR: #53283

NETCoreApp,Version=2.x|3.0 -> .NETCoreApp,Version=3.1

  • Microsoft.Win32.SystemEvents
  • System.Data.Odbc
  • System.Diagnostics.EventLog
  • System.ComponentModel.Composition
  • System.Diagnostics.PerformanceCounter
  • System.DirectoryServices
  • System.DirectoryServices.AccountManagement
  • System.DirectoryServices.Protocols
  • System.Management
  • System.Runtime.CompilerServices.Unsafe
  • System.Security.Principal.Windows
  • System.Speech
  • System.Text.Encoding.CodePages
  • System.Threading.Channels

PR: #53358

NETFramework,Version=4.5|4.5.1|4.6 -> .NETFramework.Version=4.6.1

  • System.Diagnostics.DiagnosticSource
  • System.Runtime.CompilerServices.Unsafe
  • System.IO.Packaging
  • System.ComponentModel.Composition.Registration
  • System.ComponentModel.Composition
  • System.DirectoryServices
  • System.DirectoryServices.AccountManagement
  • System.DirectoryServices.Protocols
  • System.IO.Packaging
  • System.Management
  • System.Reflection.Context
  • System.Runtime.Caching
  • System.Speech

PR: #53319

cc @danmoseley @ericstj @terrajobst @Anipik

@ViktorHofer ViktorHofer added this to the 6.0.0 milestone May 26, 2021
@ViktorHofer ViktorHofer self-assigned this May 26, 2021
@ghost
Copy link

ghost commented May 26, 2021

Tagging subscribers to this area: @Anipik, @safern, @ViktorHofer
See info in area-owners.md if you want to be subscribed.

Issue Details

Continuation of #47530

The runtime repository currently produces 102 packages from libraries of which 25 of those contain assets which will be unsupported when we release .NET 6 in November 2021. The list of unsupported assets includes netstandard1.x assets as those apply to unsupported application frameworks only as in any case where a netstandard1.x asset is present, a netstandard2.0 (and in most cases a net461 asset) exists as well which allows to run on .NET Framework 4.6.1 or .NET Core 3.1 and above.

The reasons for trimming out unsupported assets are:

  • Simplified build graph and reduced build times
  • Less restore size as the NS1.x dependency graph doesn't need to be restored
  • Package validation costs
  • Fat packages
  • Maintenance of code bases which are not tested anymore.

Based on these disadvantages we will remove the remaining unsupported assets from packages in dotnet/runtime.

List of packages grouped by TargetFrameworkIdentifier

NETStandard,Version=1.x -> .NETStandard,Version=2.0

  • Microsoft.Extensions.HostFactoryResolver.Sources
  • System.Collections.Immutable
  • System.Diagnostics.DiagnosticSource
  • System.IO.Packaging
  • System.Numerics.Tensors
  • System.Reflection.Context
  • System.Reflection.Metadata
  • System.Runtime.CompilerServices.Unsafe
  • System.Threading.Channels
  • System.Threading.Tasks.Dataflow

NETCoreApp,Version=2.x|3.0 -> .NETCoreApp,Version=3.1

  • Microsoft.Win32.SystemEvents
  • System.Data.Odbc
  • System.Diagnostics.EventLog
  • System.ComponentModel.Composition
  • System.Diagnostics.PerformanceCounter
  • System.DirectoryServices
  • System.DirectoryServices.AccountManagement
  • System.DirectoryServices.Protocols
  • System.Management
  • System.Runtime.CompilerServices.Unsafe
  • System.Security.Principal.Windows
  • System.Speech
  • System.Text.Encoding.CodePages
  • System.Threading.Channels

NETFramework,Version=4.5|4.5.1|4.6 -> .NETFramework.Version=4.6.1

  • System.Diagnostics.DiagnosticSource
  • System.Runtime.CompilerServices.Unsafe
  • System.IO.Packaging
  • System.ComponentModel.Composition.Registration
  • System.ComponentModel.Composition
  • System.DirectoryServices
  • System.DirectoryServices.AccountManagement
  • System.DirectoryServices.Protocols
  • System.IO.Packaging
  • System.Management
  • System.Reflection.Context
  • System.Runtime.Caching
  • System.Speech

cc @danmoseley @ericstj @terrajobst @Anipik

Author: ViktorHofer
Assignees: ViktorHofer
Labels:

area-Infrastructure-libraries

Milestone: 6.0.0

@dotnet-issue-labeler dotnet-issue-labeler bot added the untriaged New issue has not been triaged by the area owner label May 26, 2021
ViktorHofer added a commit to ViktorHofer/runtime that referenced this issue May 26, 2021
These ten projects still built for netstandard1.x. This PR
trims out these assets from both the build which also results
in them not being packaged anymore as there is no harvesting
mechanism in the repository anymore.

Suppressing the package warnings for the intentionally dropped
assets and cleaning up conditions in the project file as well.

For more details please see the reasoning in the linked issue.

Contributes to dotnet#53282
@ViktorHofer ViktorHofer removed the untriaged New issue has not been triaged by the area owner label May 26, 2021
@danmoseley danmoseley added breaking-change Issue or PR that represents a breaking API or functional change over a prerelease. needs-breaking-change-doc-created Breaking changes need an issue opened with https://github.com/dotnet/docs/issues/new?template=dotnet labels May 26, 2021
ViktorHofer added a commit that referenced this issue May 26, 2021
* Remove NS1.x assets from build and packaging

These ten projects still built for netstandard1.x. This PR
trims out these assets from both the build which also results
in them not being packaged anymore as there is no harvesting
mechanism in the repository anymore.

Suppressing the package warnings for the intentionally dropped
assets and cleaning up conditions in the project file as well.

For more details please see the reasoning in the linked issue.

Contributes to #53282
ViktorHofer added a commit to ViktorHofer/runtime that referenced this issue May 26, 2021
Only a very few number of projects still built for net45-net46.
This PR trims out these assets from the build which of course
results in them not being packaged (as there is no harvesting
mechanism in the repository present anymore).

Suppressing the package warnings for the intentionally dropped
assets and cleaning up conditions in the project file as well.

For more details please see the reasoning in the linked issue.

Contributes to dotnet#53282
@grbell-ms
Copy link
Member

Aren't net452, net460, and net461 supported through April 2022?
https://docs.microsoft.com/en-us/lifecycle/products/microsoft-net-framework

ViktorHofer added a commit that referenced this issue May 27, 2021
#53319)

Only a very few number of projects still built for net45-net46.
This PR trims out these assets from the build which of course
results in them not being packaged (as there is no harvesting
mechanism in the repository present anymore).

Suppressing the package warnings for the intentionally dropped
assets and cleaning up conditions in the project file as well.

For more details please see the reasoning in the linked issue.

Contributes to #53282
ViktorHofer added a commit to ViktorHofer/runtime that referenced this issue May 27, 2021
Upgrading the netcoreapp2.x and netcoreapp3.0 build configurations in
projects to netcoreapp3.1 and cleaning up conditions so that future
tfm upgrades require less project file changes.

Adding NETStandardError markers to prevent available netstandard2.0
assets being picked instead, same as already done for System.Speech
and others.

For more details please see the reasoning in the linked issue.

Contributes to dotnet#53282
@ViktorHofer
Copy link
Member Author

Aren't net452, net460, and net461 supported through April 2022?
https://docs.microsoft.com/en-us/lifecycle/products/microsoft-net-framework

You are right. For .NET Framework we decided to upgrade to net461 as that's the earliest version that support .NET Standard 2.0 which is the baseline for our packages. The table above shows that only 13 packages targeted an earlier version of .NET Framework as the majority already moved to net461 or later.

Thanks for linking to the document. That indicates that we want to upgrade our .NET Framework assets again when we branch off for NET7 which will likely release next year in November.

@grbell-ms
Copy link
Member

I was confused about the phrase "assets which will be unsupported when we release .NET 6 in November 2021". I interpreted that as "assets that target frameworks which will be unsupported when we release .NET 6 in November 2021". But I guess you meant "assets which will be unsupported by .NET 6 when we release in November 2021", which makes more sense.

ViktorHofer added a commit that referenced this issue May 28, 2021
Upgrading the netcoreapp2.x and netcoreapp3.0 build configurations in
projects to netcoreapp3.1 and cleaning up conditions so that future
tfm upgrades require less project file changes.

Adding NETStandardError markers to prevent available netstandard2.0
assets being picked instead, same as already done for System.Speech
and others.

For more details please see the reasoning in the linked issue.

Contributes to #53282
@Anipik Anipik modified the milestones: 6.0.0, 7.0.0 Aug 4, 2021
@ViktorHofer
Copy link
Member Author

Closing as work is completed.

@ghost ghost locked as resolved and limited conversation to collaborators Sep 7, 2021
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
area-Infrastructure-libraries breaking-change Issue or PR that represents a breaking API or functional change over a prerelease. needs-breaking-change-doc-created Breaking changes need an issue opened with https://github.com/dotnet/docs/issues/new?template=dotnet
Projects
None yet
Development

No branches or pull requests

4 participants