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

Eliminate obsolete API warnings/errors in product source-build #5496

Merged
merged 1 commit into from
Nov 9, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,9 @@ public PackageSourceException(string message)
{
}

#if NET8_0_OR_GREATER
[Obsolete(DiagnosticId = "SYSLIB0051")] // https://github.com/dotnet/docs/issues/34893
#endif
protected PackageSourceException(SerializationInfo info, StreamingContext context) : base(info, context)
{
}
Expand Down
3 changes: 3 additions & 0 deletions src/NuGet.Core/NuGet.Commands/Common/CommandException.cs
Original file line number Diff line number Diff line change
Expand Up @@ -29,6 +29,9 @@ public CommandException(string message, Exception exception)
{
}

#if NET8_0_OR_GREATER
[Obsolete(DiagnosticId = "SYSLIB0051")] // https://github.com/dotnet/docs/issues/34893
#endif
protected CommandException(SerializationInfo info, StreamingContext context)
: base(info, context)
{
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -22,6 +22,9 @@ public NuGetConfigurationException(string message, Exception innerException)
{
}

#if NET8_0_OR_GREATER
[Obsolete(DiagnosticId = "SYSLIB0051")] // https://github.com/dotnet/docs/issues/34893
#endif
protected NuGetConfigurationException(SerializationInfo info, StreamingContext context) : base(info, context)
{
}
Expand Down
3 changes: 3 additions & 0 deletions src/NuGet.Core/NuGet.Frameworks/FrameworkException.cs
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,9 @@ public FrameworkException(string message)
{
}

#if NET8_0_OR_GREATER
[Obsolete(DiagnosticId = "SYSLIB0051")] // https://github.com/dotnet/docs/issues/34893
#endif
protected FrameworkException(SerializationInfo info, StreamingContext context) : base(info, context)
{
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -18,6 +18,9 @@ public NuGetLicenseExpressionParsingException(string message, Exception innerExc
{
}

#if NET8_0_OR_GREATER
[Obsolete(DiagnosticId = "SYSLIB0051")] // https://github.com/dotnet/docs/issues/34893
#endif
protected NuGetLicenseExpressionParsingException(SerializationInfo info, StreamingContext context) : base(info, context)
{
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -18,6 +18,9 @@ public FatalProtocolException(string message, Exception innerException) : base(m
{
}

#if NET8_0_OR_GREATER
[Obsolete(DiagnosticId = "SYSLIB0051")] // https://github.com/dotnet/docs/issues/34893
#endif
protected FatalProtocolException(SerializationInfo info, StreamingContext context) : base(info, context)
{
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -23,6 +23,9 @@ public InvalidCacheProtocolException(string message, Exception innerException)
{
}

#if NET8_0_OR_GREATER
[Obsolete(DiagnosticId = "SYSLIB0051")] // https://github.com/dotnet/docs/issues/34893
#endif
protected InvalidCacheProtocolException(SerializationInfo info, StreamingContext context) : base(info, context)
{
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -22,6 +22,9 @@ public NuGetProtocolException(string message, Exception innerException)
{
}

#if NET8_0_OR_GREATER
[Obsolete(DiagnosticId = "SYSLIB0051")] // https://github.com/dotnet/docs/issues/34893
#endif
protected NuGetProtocolException(SerializationInfo info, StreamingContext context) : base(info, context)
{
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,9 @@ public RetriableProtocolException(string message, Exception innerException) : ba
{
}

#if NET8_0_OR_GREATER
[Obsolete(DiagnosticId = "SYSLIB0051")] // https://github.com/dotnet/docs/issues/34893
#endif
protected RetriableProtocolException(SerializationInfo info, StreamingContext context) : base(info, context)
{
}
Expand Down
3 changes: 3 additions & 0 deletions src/NuGet.Core/NuGet.Protocol/Plugins/PluginException.cs
Original file line number Diff line number Diff line change
Expand Up @@ -31,6 +31,9 @@ public PluginException(string message, Exception innerException)
{
}

#if NET8_0_OR_GREATER
[Obsolete(DiagnosticId = "SYSLIB0051")] // https://github.com/dotnet/docs/issues/34893
#endif
private PluginException(SerializationInfo info, StreamingContext context) : base(info, context)
{
}
Expand Down
3 changes: 3 additions & 0 deletions src/NuGet.Core/NuGet.Protocol/Plugins/ProtocolException.cs
Original file line number Diff line number Diff line change
Expand Up @@ -31,6 +31,9 @@ public ProtocolException(string message, Exception innerException)
{
}

#if NET8_0_OR_GREATER
[Obsolete(DiagnosticId = "SYSLIB0051")] // https://github.com/dotnet/docs/issues/34893
#endif
private ProtocolException(SerializationInfo info, StreamingContext context) : base(info, context)
{
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,9 @@ public NuGetResolverConstraintException(string message)
{
}

#if NET8_0_OR_GREATER
[Obsolete(DiagnosticId = "SYSLIB0051")] // https://github.com/dotnet/docs/issues/34893
#endif
protected NuGetResolverConstraintException(SerializationInfo info, StreamingContext context) : base(info, context)
{
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,9 @@ public NuGetResolverException(string message)
{
}

#if NET8_0_OR_GREATER
[Obsolete(DiagnosticId = "SYSLIB0051")] // https://github.com/dotnet/docs/issues/34893
#endif
protected NuGetResolverException(SerializationInfo info, StreamingContext context) : base(info, context)
{
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,9 @@ public NuGetResolverInputException(string message)
{
}

#if NET8_0_OR_GREATER
[Obsolete(DiagnosticId = "SYSLIB0051")] // https://github.com/dotnet/docs/issues/34893
#endif
protected NuGetResolverInputException(SerializationInfo info, StreamingContext context) : base(info, context)
{
}
Expand Down