MassTransit 5.0.1 assembly mismatch - public key token
See original GitHub issueIs this a bug report?
Yes
Can you also reproduce the problem with the lastest version?
Yes (stable 5.0.1 and 5.0.1.1500-develop). It works fine with 4.0.1.
Environment
- Operating system: Windows 10
- Visual Studio version: 2017
- Dotnet version: .NET 4.7.1 and netstandard 2.0
Steps to Reproduce
Hi, there might be an issue about MassTransit dll signatures in the latest version:
- Create a netstandard2.0 nuget package or dll which uses MassTransit.
- Create a new .net project and call this package.
- Start the solution.
Expected Behavior
Masstransit server starts.
Actual Behavior
A MassTransit exception is thrown:
Message "Could not load file or assembly 'MassTransit, Version=5.0.1.1500, Culture=neutral, PublicKeyToken=null' or one of its dependencies.
The located assembly's manifest definition does not match the assembly reference. (Exception from HRESULT: 0x80131040)"
FusionLog "=== Pre-bind state information ===
LOG: DisplayName = MassTransit, Version=5.0.1.1500, Culture=neutral, PublicKeyToken=null\n (Fully-specified)
LOG: Appbase = file:///D:/LocalSources/TestMassTransit3/TestMassTransit3/bin/Debug/net471/
LOG: Initial PrivatePath = NULL
Calling assembly : Spd.Communication.Queuing, Version=2.3.2.0, Culture=neutral, PublicKeyToken=null.
===
LOG: This bind starts in default load context.
LOG: Using application configuration file: D:\\LocalSources\\TestMassTransit3\\TestMassTransit3\\bin\\Debug\\net471\\TestMassTransit3.exe.Config
LOG: Using host configuration file:
LOG: Using machine configuration file from C:\\Windows\\Microsoft.NET\\Framework\\v4.0.30319\\config\\machine.config.
LOG: Policy not being applied to reference at this time (private, custom, partial, or location-based assembly bind).
LOG: Attempting download of new URL file:///D:/LocalSources/TestMassTransit3/TestMassTransit3/bin/Debug/net471/MassTransit.DLL.
WRN: Comparing the assembly name resulted in the mismatch: PUBLIC KEY TOKEN
ERR: Failed to complete setup of assembly (hr = 0x80131040). Probing terminated."
This error only occurs when referencing MassTransit through an external library, if we call the same code directly everything is fine.
Thanks for your help.
Issue Analytics
- State:
- Created 5 years ago
- Comments:15 (8 by maintainers)
Top Results From Across the Web
FileLoadException on DLL Load
dll I get 75a99a2a5bcd4c96. I'm honestly at a loss how at runtime it thinks the public key token is null and why there...
Read more >How to: Determine the Public Key Token of the Windows ...
Describes how to determine the public key token of the Windows client control add-in and .NET Framework assembly.
Read more >Oracle Identity Management Integration Guide
Oracle Directory Integration and Provisioning-Only Installation. ... during transmission by using public-key encryption available with SSL. In public-key.
Read more >Cannot find assembly 'mscorlib, version=2.0.5.0, culture= ...
AssemblyLoadException: Cannot find assembly 'mscorlib, version=2.0.5.0, culture=neutral, publickeytoken=7cec85d7bea7798e'. [Public key mismatch]
Read more >Untitled
Daktaras ozas dieta, Morality guide mass effect, Mateevici 75 chisinau. ... Mare nostrum montpellier 2013, Network security key mismatch windows 7!
Read more >
Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free
Top Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found

Well, F*.
Talking to the runtime team at Microsoft, they’re like, yeah, this sucks. We hate strong names, but you’re F’d, so you might as well put them all back on your .NET Standard project. Of course this means I have to update the entire stack, which isn’t going to happen this week.
I tried https://www.nuget.org/packages/Brutal.Dev.StrongNameSigner/ but still cannot figure out how to make it work. My app is also a console app running as a TopShelf windows service. At the moment, I will stay with 4.0.1 and try to find time to investigate into the work around.