Exception detail not showing in error log

Topics: Writing modules
Mar 6, 2013 at 7:46 AM
Hi

I'm a newbie and have been trying to write a widget by following various online tutorials.

When I add the widget to a zone, I'm getting a "Object reference not set to an instance of an object" so I thought "look in the log file for further details" and when I did, there was nothing there.

So I placed breakpoints in OrchardLog4netLogger.cs and found the exception parameter passed in is null when the exception is caught.

As there a configuration option somewhere that tells Orchard not to log exception details?

Many thanks

Tony
Mar 6, 2013 at 8:02 AM
I managed to deduce where the exception was being thrown (Orchard 1.6, Orchard.Widgets.Controllers.AdminController AddWidget method and the reason no stacktrace is logged is because the the logger isn't being told to - it's just logging the exception message
Mar 6, 2013 at 9:35 PM
I managed to deduce where the exception was being thrown (Orchard 1.6, Orchard.Widgets.Controllers.AdminController AddWidget method and the reason no stacktrace is logged is because the the logger isn't being told to - it's just logging the exception message