Hi,
I am working on a website that is running in DXC. When we get the application log from paasportal.episerver.net we have noticed that all the errors are shown as:
"EPiServer.Global : Unhandled exception in ASP.NET
System.InvalidOperationException: The model item passed into the dictionary is of type 'System.Web.Mvc.HandleErrorInfo', but this dictionary requires a model item of type 'SearchResultsPageViewModel'."
this is even when i manually add a line to a view file that throws an error with a specific message, where i should be seeing something like:
"EPiServer.Global : Unhandled exception in ASP.NET
System.Exception: test
at ASP._Page_Views_Pages_HomePage_cshtml.Execute()
at System.Web.WebPages.WebPageBase.ExecutePageHierarchy()
at System.Web.Mvc.WebViewPage.ExecutePageHierarchy()
at System.Web.WebPages.StartPage.ExecutePageHierarchy()
etc.
I'm trying to work out if i need to configure the site differently to work on DXC and to get the correct error messages. One thing we have noticed is that when we turn CustomErrors off in the web config we get the correct error details in the application log, even though it is using the same html file to display the error message. Obviously we want to keep custom errors turned on in production so this isn't really a fix.
I'm really confused, has anyone set up a DXC site where logging is working correctly? what did you have to do differently to a regular episerver website?
Thanks in advance
Sam