Exception Thrown When Running From Command Line

Analyzes .NET assemblies for types of exceptions

Moderators: Brian Donahue, Charles Brown, Alex.Davies, AndrewH

Exception Thrown When Running From Command Line

Postby darryl_staflund » Thu Dec 13, 2007 10:25 pm

Hi Red Gate,

Congratulations on the release of Exception Hunter. It looks like a great product and is really quite innovative -- I haven't heard of a similar tool.

I tried running Exception Handler from the command-line on an application I am developing and received the following exception (NB: Here's the command-line output of my run):

Code: Select all
C:\\Work\\wm\\build>"c:\\Program Files\\Red Gate\\Exception Hunter 1\\Hunt.exe" /assembly:".\\<MyAppHere>.exe" /all /warnOnlyOnMissingReference:on
Exception Hunter Command Line V1.0.0.551
======================================================================================================================================================================================================
Copyright c Red Gate Software Ltd 2007

= Loading .NET framework
= Loading assemblies
Warning: Could not locate assembly ActiveReports.Chart, Version=4.1.0.1127, Culture=neutral, PublicKeyToken=cc4967777c49a3ff
= Calculating exceptions
Error: Unhandled exception: Could not analyse the method NativeOledbWrapper::MemoryCompare due to an exception.

*** Inner Exception: The method or operation is not implemented. (NotImplementedException)
   at bm.get_Flags()
   at aK.ModelDataFlow(W dataState)
   at g.a(Int32 , X , c , Boolean )
   at g.d()
   at g.c()
   at e.a()

*** Inner Exception: Could not analyse the method NativeOledbWrapper::MemoryCompare due to an exception. (CouldNotAnalyseMethodException)
   at e.a()
   at e.c()
   at e.a(C )
   at bw.CalculateExceptionsThrownByMethod(IClassMethod method)
   at c.PerformAnalysis()
   at RedGate.ExceptionHunter.CommandLine.CommandLine.a(String[] )

C:\\Work\\wm\\build>


Other than this particular exception, I have been able to run Exception Hunter no problem.

Darryl
darryl_staflund
 
Posts: 2
Joined: Fri Apr 06, 2007 7:01 am

Postby Brian Donahue » Fri Dec 14, 2007 2:20 pm

Hi Darryl,

We have identified a potential problem in the handling of missing dependent assemblies in the command-line version of Exception Hunter, which will be fixed in a future release.

In the meantime, the program should work without error if you specify the path to the missing assembly in the searchPaths argument:
Code: Select all
Hunt.exe" /assembly:".\\<MyAppHere>.exe" /all /searchPaths:<pathToActiveReports.chart> /warnOnlyOnMissingReference:on
We're sorry for the inconvenience.
Brian Donahue
 
Posts: 6670
Joined: Mon Aug 23, 2004 10:48 am

Same error, missing dependent assembly unknown

Postby rkpatrick » Wed Oct 15, 2008 9:22 pm

I'm currently evaluating EH and am getting the same exceptions from command line that Darryl is. However, I've tried setting the search paths (I run out of my assembly's bin directory as well) to include as many locations as I can come up with, but the error still appears. Is there some way to determine which dependent assembly is causing the issue?

BTW, this is the full line I'm currently executing (I've got another one with bin\\debug paths to every reference in the project, separated by commas):
C:\\DEV2\\LOSSMIT\\WebSite\\bin>"C:\\Program Files\\Red Gate\\Exception Hunter1\\Hunt.exe" /assembly:elmsbl.dll /all /warnOnlyOnMissingReference:on /searchPaths:"C:\\Program Files\\Microsoft Visual Studio 8\\ReportViewer","C:\\dev2\\LossMit\\WebSite\\bin" /exceptionReport:true
rkpatrick
 
Posts: 3
Joined: Wed Oct 15, 2008 9:15 pm

Postby Brian Donahue » Thu Oct 16, 2008 9:36 am

Hi,

You may want to try the latest private build of Exception Hunter 1.1. It has some improved reading of assembly metadata:

http://downloads.red-gate.com/BleedingE ... tBuild.msi
Brian Donahue
 
Posts: 6670
Joined: Mon Aug 23, 2004 10:48 am

1.1

Postby rkpatrick » Thu Oct 16, 2008 4:16 pm

Unfortunately, EH 1.1 gives me the same error.
rkpatrick
 
Posts: 3
Joined: Wed Oct 15, 2008 9:15 pm

Postby Brian Donahue » Fri Oct 17, 2008 9:54 am

Just to clarify, are you getting the warning about not being able to locate the assembly or the error about not being able to analyze a method?

If you can't analyze a method, it may just be that the assembly, or one of its' dependencies, was built using an obfuscator. These can make it difficult or impossible for Exception Hunter to disassemble the code (essectially that's their job!) and there may not be a way of analyzing this dll without getting a version that isn't obfuscated.
Brian Donahue
 
Posts: 6670
Joined: Mon Aug 23, 2004 10:48 am

Error msg

Postby rkpatrick » Fri Oct 17, 2008 3:38 pm

It's an error (happens very late in the process, but the exception report isn't generated):
Code: Select all
  Finding exceptions for public System.Boolean ELMSBL.WorkoutCreator.FileProcess
or::ProcessFile(System.String)
Error: Unhandled exception: Could not analyse the method NativeOledbWrapper::Mem
oryCompare due to an exception.

*** Inner Exception: The method or operation is not implemented. (NotImplemented
Exception)
   at bm.get_Flags()
   at aK.ModelDataFlow(X dataState)
   at g.a(Int32 , Y , c , Boolean )
   at g.d()
   at g.c()
   at e.a()

*** Inner Exception: Could not analyse the method NativeOledbWrapper::MemoryComp
are due to an exception. (CouldNotAnalyseMethodException)
   at e.a()
   at e.c()
   at e.a(D , aa , IList`1 )
   at bw.CalculateExceptionsThrownByMethod(IClassMethod method, IClass instanceC
lass)
   at bw.CalculateExceptionsThrownByMethod(IClassMethod method)
   at c.PerformAnalysis()
   at RedGate.ExceptionHunter.CommandLine.CommandLine.a(String[] )
Exception Hunter finished with code 1
rkpatrick
 
Posts: 3
Joined: Wed Oct 15, 2008 9:15 pm

Postby Mojo Hand » Tue Mar 24, 2009 4:03 pm

I get the same error.

Code: Select all
Error: Unhandled exception: Could not analyse the method NativeOledbWrapper::MemoryCompare due to an exception.

*** Inner Exception: The method or operation is not implemented. (NotImplementedException)
   at bm.get_Flags()
   at aK.ModelDataFlow(W dataState)
   at g.a(Int32 , X , c , Boolean )
   at g.d()
   at g.c()
   at e.a()

*** Inner Exception: Could not analyse the method NativeOledbWrapper::MemoryCompare due to an exception. (CouldNotAnalys
eMethodException)
   at e.a()
   at e.c()
   at e.a(C )
   at bw.CalculateExceptionsThrownByMethod(IClassMethod method)
   at c.PerformAnalysis()
   at RedGate.ExceptionHunter.CommandLine.CommandLine.a(String[] )
Exception Hunter finished with code 1
Mojo Hand
 
Posts: 4
Joined: Fri Mar 06, 2009 8:53 pm


Return to Exception Hunter 1

Who is online

Users browsing this forum: No registered users and 0 guests