Skip to content

Could not load Hangfire.Core when using Sentry.Hangfire. A strongly-named assembly is required. #4082

@RudeySH

Description

@RudeySH

Package

Other

.NET Flavor

.NET Framework

.NET Version

4.8

OS

Windows

OS Version

No response

Development Environment

Visual Studio v17.x

SDK Version

9.11.0

Self-Hosted Sentry Version

No response

Workload Versions

N/A

UseSentry or SentrySdk.Init call

this.sentrySdk = SentrySdk.Init(options =>
{
    options.Dsn = "...";
    options.Environment = "Production";

    options.CaptureFailedRequests = true;
    options.FailedRequestStatusCodes.Add((400, 499));
    options.SendDefaultPii = true;
    options.TracesSampleRate = 0.1;

    options.AddEntityFramework();
    options.AddAspNet(RequestSize.Always);
});

Steps to Reproduce

  • Install Hangfire.Core (1.8.12), Sentry (5.5.0) and Sentry.Hangfire (5.5.0)
  • Hangfire.GlobalConfiguration.Configuration.UseSentry()
  • Start debugging

Expected Result

Application should start without exceptions.

Actual Result

Application throws exception.

Could not load file or assembly 'Hangfire.Core, Version=1.8.12.0, Culture=neutral, PublicKeyToken=null' or one of its dependencies. A strongly-named assembly is required. (Exception from HRESULT: 0x80131044)

Metadata

Metadata

Assignees

Labels

No labels
No labels

Projects

Status

Done

Status

No status

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions