error message under profiler - could not load assembly

Use this forum for questions on how to use .NET Memory Profiler and how to analyse memory usage.
Post Reply
andrew_k

error message under profiler - could not load assembly

Post by andrew_k » Tue Sep 06, 2011 11:17 am

Could someone help please.

I've got error message when started under profiler - could not load assembly ...or one of its dependencies. A strongly-named assembly is required.
Application works fine without profiling.

Thanks

Andreas Suurkuusk
Posts: 1029
Joined: Wed Mar 02, 2005 7:53 pm

Re: error message under profiler - could not load assembly

Post by Andreas Suurkuusk » Tue Sep 06, 2011 3:36 pm

To be able to investigate this problem we will need some additional information. Do you have any information about the assembly that fails to load? You can probably get more information by using the Assembly Binding Log Viewer (fuslogvw).

What version of the profiler are you using?
Best regards,

Andreas Suurkuusk
SciTech Software AB

Guest

Re: error message under profiler - could not load assembly

Post by Guest » Wed Sep 07, 2011 2:51 pm

Andreas,
Thanks for reply.
Profiler's version is 3.5.
We use ILMerge that produces signed assembly. I looked into that assembly via Reflector and it seems that the assembly that causes error is not signed. I know, that we cannot add non-signed assembly reference to assembly with strong name, but ILMerge somehow bypasses this. So the issue is that app works fine without profiling, but under profiling - System.IO.FileLoadException - could not load assembly.... exception occurs.

That assembly comes from vendor. I tried to disassemble and then assemble and sign it with our key, but I'm getting error while assembling.

Maybe you have any ideas?

Andreas Suurkuusk
Posts: 1029
Joined: Wed Mar 02, 2005 7:53 pm

Re: error message under profiler - could not load assembly

Post by Andreas Suurkuusk » Fri Sep 09, 2011 11:42 am

If I understand you correctly, you have a signed assembly that references an unsigned assembly, is that correct? In this case you wil get an assembly load failure. Or at least should, I'm not sure why it works when running outside the profiler.

Disassembling an assembly using ILDasm and then recompile using ILasm with signing should work well. Wht kind of error are you seeing?
Best regards,

Andreas Suurkuusk
SciTech Software AB

Guest

Re: error message under profiler - could not load assembly

Post by Guest » Mon Sep 12, 2011 12:40 pm

Andreas,

Yeah, thats correct. Using ILMerge it's possible to generate signed assembly that references unsigned. I don't understand how it works outside profiler. It should FAIL.
I'm getting error "Failure", while assembling. This message doesn't help at all(.
Anyway. I found source code for reefrenced unsigned assembly on vendor's site and signed it. So It works fine now.

Thanks for your help.

Post Reply

Who is online

Users browsing this forum: Bing [Bot] and 31 guests