Profiler add a second mscorlib assembly
philippe.martens
Posts: 9
When recording performance for a program using Linq for NHibernate, the program crashed with a Type initilization error exception (but works normally outside of performance profiler).
After some investigation, it boils down to Remotion Linq executing
var mscorlibReference = Assembly.GetExecutingAssembly().GetReferencedAssemblies().Single (name => name.Name == "mscorlib")
which is quite reasonable.
But running with performance profiler version 8.0, every assembly gets one supplementary referenced assembly, namely mscorlib version 1.0.3300.0, and thus seems to reference 2 mscorlib assemblies.
After some investigation, it boils down to Remotion Linq executing
var mscorlibReference = Assembly.GetExecutingAssembly().GetReferencedAssemblies().Single (name => name.Name == "mscorlib")
which is quite reasonable.
But running with performance profiler version 8.0, every assembly gets one supplementary referenced assembly, namely mscorlib version 1.0.3300.0, and thus seems to reference 2 mscorlib assemblies.
Comments
Thanks for letting us know. I've added this to our bug tracking system (reference: PP-3428) for investigation.
Dom.
Project Manager,
Redgate.
The developers have looked at this, and we have confirmed this issue.
However, it looks like Re-motion have fixed the bug at their end (https://www.re-motion.org/jira/browse/RM-3832), so upgrading re-linq may help you.
Dom.
Project Manager,
Redgate.
Upgrading Re-Linq would then require upgrading NHibernate, and the latest versions come with an embedded proxy generator which doesn't support generic methods in generic classes (which I use in my infrastructure classes).
I would then need to endorse support for the Castle based ProxyGenerator from the version I'm currently using...
For now, I've just patched Re-Linq and rebuild it and NHibernate, but only for dev/test purposes.
So I'll wait for your correction of the problem.
Regards.