Skip to content
Merged
Show file tree
Hide file tree
Changes from 1 commit
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
Prev Previous commit
Next Next commit
Bump framework targets from net462 to net48
  • Loading branch information
jamescrosswell committed Jun 10, 2025
commit 613ebf24cb0f87c5da65536da91e957433cddf50
2 changes: 1 addition & 1 deletion src/Sentry.AspNet/Sentry.AspNet.csproj
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
<Project Sdk="Microsoft.NET.Sdk">

<PropertyGroup>
<TargetFramework>net462</TargetFramework>
<TargetFramework>net48</TargetFramework>
<PackageTags>$(PackageTags);AspNet;MVC</PackageTags>
<Description>Official ASP.NET integration for Sentry - Open-source error tracking that helps developers monitor and fix crashes in real time.</Description>
</PropertyGroup>
Expand Down
2 changes: 1 addition & 1 deletion src/Sentry.DiagnosticSource/Sentry.DiagnosticSource.csproj
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
<Project Sdk="Microsoft.NET.Sdk">

<PropertyGroup>
<TargetFrameworks>netstandard2.1;netstandard2.0;net462</TargetFrameworks>
<TargetFrameworks>netstandard2.1;netstandard2.0;net48</TargetFrameworks>
<PackageTags>$(PackageTags);Logging;Microsoft.Extensions.Logging</PackageTags>
<Description>
Official Diagnostic.Listener integration for Sentry - Open-source error tracking that helps developers monitor and fix crashes in real time. Note: This package is not needed when using Sentry with .NET Core 3 or higher.
Expand Down
4 changes: 2 additions & 2 deletions src/Sentry.EntityFramework/Sentry.EntityFramework.csproj
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
<Project Sdk="Microsoft.NET.Sdk">

<PropertyGroup>
<TargetFrameworks>net462;netstandard2.1</TargetFrameworks>
<TargetFrameworks>net48;netstandard2.1</TargetFrameworks>
<Description>Official Entity Framework 6 integration for Sentry - Open-source error tracking that helps developers monitor and fix crashes in real time.</Description>
<PackageTags>$(PackageTags);EntityFramework;EF;EF6</PackageTags>
</PropertyGroup>
Expand All @@ -21,7 +21,7 @@
<Using Include="Sentry.Integrations" />
</ItemGroup>

<ItemGroup Condition="'$(TargetFramework)' == 'net462'">
<ItemGroup Condition="'$(TargetFramework)' == 'net48'">
<PackageReference Include="EntityFramework" Version="6.2.0" />
</ItemGroup>

Expand Down
2 changes: 1 addition & 1 deletion src/Sentry.Hangfire/Sentry.Hangfire.csproj
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
<PropertyGroup>
<Description>Official Hangfire integration for Sentry - Open-source error tracking that helps developers monitor and fix crashes in real time.</Description>
<PackageTags>$(PackageTags);Hangfire</PackageTags>
<TargetFrameworks>net9.0;net8.0;net462</TargetFrameworks>
<TargetFrameworks>net9.0;net8.0;net48</TargetFrameworks>
<ImplicitUsings>enable</ImplicitUsings>
<SignAssembly>false</SignAssembly>
</PropertyGroup>
Expand Down
2 changes: 1 addition & 1 deletion src/Sentry.NLog/Sentry.NLog.csproj
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
<Project Sdk="Microsoft.NET.Sdk">

<PropertyGroup>
<TargetFrameworks>net9.0;net8.0;netstandard2.0;net462</TargetFrameworks>
<TargetFrameworks>net9.0;net8.0;netstandard2.0;net48</TargetFrameworks>
<PackageTags>$(PackageTags);Logging;NLog</PackageTags>
<Description>Official NLog integration for Sentry - Open-source error tracking that helps developers monitor and fix crashes in real time.</Description>
<CLSCompliant>true</CLSCompliant>
Expand Down
6 changes: 5 additions & 1 deletion src/Sentry.OpenTelemetry/Sentry.OpenTelemetry.csproj
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
<PropertyGroup>
<Description>Official OpenTelemetry integration for Sentry - Open-source error tracking that helps developers monitor and fix crashes in real time.</Description>
<PackageTags>$(PackageTags);OpenTelemetry</PackageTags>
<TargetFrameworks>net9.0;net8.0;netstandard2.1;netstandard2.0;net462</TargetFrameworks>
<TargetFrameworks>net9.0;net8.0;netstandard2.1;netstandard2.0;net48</TargetFrameworks>
<ImplicitUsings>enable</ImplicitUsings>
</PropertyGroup>

Expand All @@ -20,6 +20,10 @@
<PackageReference Include="OpenTelemetry" Version="1.6.0" />
</ItemGroup>

<ItemGroup Condition="'$(TargetFramework)' == 'net48'">
<PackageReference Include="System.Net.Http" Version="4.3.4" />
</ItemGroup>

<ItemGroup>
<InternalsVisibleTo Include="Sentry.OpenTelemetry.AspNetCore" PublicKey="$(SentryPublicKey)" />
<InternalsVisibleTo Include="Sentry.OpenTelemetry.Tests" PublicKey="$(SentryPublicKey)" />
Expand Down
6 changes: 3 additions & 3 deletions src/Sentry.Serilog/Sentry.Serilog.csproj
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
<Project Sdk="Microsoft.NET.Sdk">

<PropertyGroup>
<TargetFrameworks>net9.0;net8.0;netstandard2.1;netstandard2.0;net462</TargetFrameworks>
<TargetFrameworks>net9.0;net8.0;netstandard2.1;netstandard2.0;net48</TargetFrameworks>
<PackageTags>$(PackageTags);Logging;Serilog</PackageTags>
<Description>Official Serilog integration for Sentry - Open-source error tracking that helps developers monitor and fix crashes in real time.</Description>
<CLSCompliant>true</CLSCompliant>
Expand All @@ -27,11 +27,11 @@
<Using Include="Serilog.Formatting" />
</ItemGroup>

<ItemGroup Condition="$(TargetFramework) == 'net462' or $(TargetFramework) == 'netstandard2.0'">
<ItemGroup Condition="$(TargetFramework) == 'net48' or $(TargetFramework) == 'netstandard2.0'">
<PackageReference Include="Serilog" Version="2.7.1" />
</ItemGroup>

<ItemGroup Condition="$(TargetFramework) != 'net462' and $(TargetFramework) != 'netstandard2.0'">
<ItemGroup Condition="$(TargetFramework) != 'net48' and $(TargetFramework) != 'netstandard2.0'">
<PackageReference Include="Serilog" Version="2.10.0" />
</ItemGroup>

Expand Down
2 changes: 2 additions & 0 deletions src/Sentry/HttpStatusCodeRange.cs
Original file line number Diff line number Diff line change
@@ -1,3 +1,5 @@
using System;

namespace Sentry;

/// <summary>
Expand Down
2 changes: 1 addition & 1 deletion src/Sentry/Internal/RandomValuesFactory.cs
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ internal abstract class RandomValuesFactory
public abstract double NextDouble();
public abstract void NextBytes(byte[] bytes);

#if !(NETSTANDARD2_0 || NET462)
#if !(NETSTANDARD2_0 || NET48X)
public abstract void NextBytes(Span<byte> bytes);
#endif

Expand Down
2 changes: 1 addition & 1 deletion src/Sentry/Internal/SynchronizedRandomValuesFactory.cs
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ internal class SynchronizedRandomValuesFactory : RandomValuesFactory
public override double NextDouble() => Random.NextDouble();
public override void NextBytes(byte[] bytes) => Random.NextBytes(bytes);

#if !(NETSTANDARD2_0 || NET462)
#if !(NETSTANDARD2_0 || NET48X)
public override void NextBytes(Span<byte> bytes) => Random.NextBytes(bytes);
#endif

Expand Down
2 changes: 1 addition & 1 deletion src/Sentry/Sentry.csproj
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@
</PropertyGroup>

<PropertyGroup Condition="'$(SolutionName)' != 'Sentry.Unity'">
<TargetFrameworks>net9.0;net8.0;netstandard2.1;netstandard2.0;net462</TargetFrameworks>
<TargetFrameworks>net9.0;net8.0;netstandard2.1;netstandard2.0;net48</TargetFrameworks>
<TargetFrameworks Condition="'$(NO_ANDROID)' == ''">$(TargetFrameworks);net9.0-android35.0;net8.0-android34.0</TargetFrameworks>
<TargetFrameworks Condition="'$(NO_IOS)' == '' And $([MSBuild]::IsOSPlatform('OSX'))">$(TargetFrameworks);net9.0-ios18.0;net8.0-ios17.0</TargetFrameworks>
<TargetFrameworks Condition="'$(NO_MACCATALYST)' == '' And $([MSBuild]::IsOSPlatform('OSX'))">$(TargetFrameworks);net9.0-maccatalyst18.0;net8.0-maccatalyst17.0</TargetFrameworks>
Expand Down
4 changes: 2 additions & 2 deletions src/Sentry/SpanId.cs
Original file line number Diff line number Diff line change
Expand Up @@ -48,7 +48,7 @@ namespace Sentry;
/// </summary>
public static SpanId Create()
{
#if NETSTANDARD2_0 || NET462
#if NETSTANDARD2_0 || NET48X
byte[] buf = new byte[8];
#else
Span<byte> buf = stackalloc byte[8];
Expand All @@ -57,7 +57,7 @@ public static SpanId Create()
Random.NextBytes(buf);

var random = BitConverter.ToInt64(buf
#if NETSTANDARD2_0 || NET462
#if NETSTANDARD2_0 || NET48X
, 0);
#else
);
Expand Down
Loading