question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Sentry.AspNetCore don't work on .NET Core 3 preview 7

See original GitHub issue

Hey,

Today after update my project to .NET Core 3 preview 7 i got error after start server:

Microsoft.AspNetCore.Server.Kestrel[13]
      => RequestPath:/ RequestId:0HLOFIKBADKBP:00000001, SpanId:|21217a1d-4070281b8cc56ef0., TraceId:21217a1d-4070281b8cc56ef0, ParentId:
      Connection id "0HLOFIKBADKBP", Request id "0HLOFIKBADKBP:00000001": An unhandled exception was thrown by the application.
System.TypeLoadException: Could not load type 'Microsoft.AspNetCore.Http.Internal.BufferingHelper' from assembly 'Microsoft.AspNetCore.Http, Version=3.0.0.0, Culture=neutral, PublicKeyToken=adb9793829ddae60'.
   at Sentry.AspNetCore.SentryMiddleware.InvokeAsync(HttpContext context)
   at System.Runtime.CompilerServices.AsyncMethodBuilderCore.Start[TStateMachine](TStateMachine& stateMachine)
   at Sentry.AspNetCore.SentryMiddleware.InvokeAsync(HttpContext context)
   at Microsoft.AspNetCore.HostFiltering.HostFilteringMiddleware.Invoke(HttpContext context)
   at Microsoft.AspNetCore.Hosting.HostingApplication.ProcessRequestAsync(Context context)
   at Microsoft.AspNetCore.Server.Kestrel.Core.Internal.Http.HttpProtocol.ProcessRequests[TContext](IHttpApplication`1 application)

my Program.cs:

public static IHostBuilder CreateHostBuilder(string[] args) =>
            Host.CreateDefaultBuilder(args)
                .ConfigureWebHostDefaults(webBuilder =>
                {
                    webBuilder.UseStartup<Startup>()
                    .UseKestrel(
                        options =>
                        {
                            options.AllowSynchronousIO = true;
                        }).UseSentry();
                });

I tried both versions: <PackageReference Include="Sentry.AspNetCore" Version="1.2.0" /> <PackageReference Include="Sentry.AspNetCore" Version="2.0.0-beta2" />

Issue Analytics

  • State:closed
  • Created 4 years ago
  • Comments:9 (5 by maintainers)

github_iconTop GitHub Comments

4reactions
bruno-garciacommented, Jul 24, 2019

Thanks for raising this! EnableRewind was under the Microsoft.AspNetCore.Http.Internal namespace so I’m guess this will be a won’t fix from the ASP.NET team.

It seems like the middleware should be calling EnableBuffering instead though.

2reactions
bruno-garciacommented, Jul 26, 2019

@mrlife Just made a release: https://www.nuget.org/packages/Sentry/2.0.0-beta3 Please let us know if you find any issues.

Read more comments on GitHub >

github_iconTop Results From Across the Web

Troubleshooting for ASP.NET Core
Sentry CLI not configured. The following message may appear in your build output: The Sentry CLI is not fully configured with authentication, organization,...
Read more >
Sentry.AspNetCore 3.35.1
Official ASP.NET Core integration for Sentry - Open-source error tracking that helps developers monitor and fix crashes in real time.
Read more >
ASP.NET Core updates in .NET 8 Preview 7
NET 8 Preview 7 is now available and includes many great new improvements to ASP.NET Core. Here's a summary of what's new in...
Read more >
Sentry with Serilog in NET Core 3.1 worker
I have a NET Core 3.1 worker configured like this: ... Console log works properly but it won't log to Sentry . What...
Read more >
sentry-dotnet
Sentry SDK for .NET. ... Integrations, Downloads, NuGet Stable, NuGet Preview, Documentation ... NET Core 3.1 on Windows, macOS and Linux .
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found