Internal Server Error: undefined

4 posts, 0 answers
  1. Jan
    Jan avatar
    8 posts
    Member since:
    Sep 2014

    Posted 09 Oct 2014 Link to this post

    I built a small test web application using your mvc how to and example reports and everything worked great. I then replicated my steps inside of a larger web application and when I try to bring up a report inside the html 5 viewer now I get an "Internal Server Error: undefined" message inside the viewer. No further information that I can see. What can I do to find out what's wrong? Trial and error so far has not resulted in anything...

    Thanks
  2. Jan
    Jan avatar
    8 posts
    Member since:
    Sep 2014

    Posted 09 Oct 2014 in reply to Jan Link to this post

    Did some more digging with Fiddler (great tool btw!)... the issues seems to be when the request to /api/reports/ is made, in particular /api/reports/clients

    When I try to access that manually I receive an HTTP 405 Method Not Allowed error. In my small test application this works fine.

    I'm not very familiar with webapi, but I did add the code in WebApiConfig.cs as per the documentation... where do I go from here?
  3. Jan
    Jan avatar
    8 posts
    Member since:
    Sep 2014

    Posted 09 Oct 2014 Link to this post

    Two requests to /api/reports/clients, the first one shows up at 401:

    HTTP/1.1 401 Unauthorized<br>Content-Type: text/html; charset=us-ascii<br>Server: Microsoft-HTTPAPI/2.0<br>WWW-Authenticate: Negotiate oYHWMIHToAMKAQGhDAYKKwYBBAGCNwICCqKBvQSBuk5UTE1TU1AAAgAAAAwADAA4AAAAFcKJ4sXJ92W9Y8PoEF/4AQAAAAB2AHYARAAAAAYBsR0AAAAPQQBQAEUARwBCAEMAAgAMAEEAUABFAEcAQgBDAAEACgBQAEUARQBLADcABAAQAGEAcABlAGcALgBkAG4AcwADABwAUABlAGUAawA3AC4AYQBwAGUAZwAuAGQAbgBzAAUAEABhAHAAZQBnAC4AZABuAHMABwAIAOD/KG3u488BAAAAAA==<br>Date: Thu, 09 Oct 2014 18:25:39 GMT<br>Content-Length: 341<br>Proxy-Support: Session-Based-Authentication<br><br><!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01//EN""http://www.w3.org/TR/html4/strict.dtd"><br><HTML><HEAD><TITLE>Not Authorized</TITLE><br><META HTTP-EQUIV="Content-Type" Content="text/html; charset=us-ascii"></HEAD><br><BODY><h2>Not Authorized</h2><br><hr><p>HTTP Error 401. The requested resource requires user authentication.</p><br></BODY></HTML><br><br>

    The second, 500, shows:
    HTTP/1.1 500 Internal Server Error
    Cache-Control: no-cache
    Pragma: no-cache
    Content-Type: application/json; charset=utf-8
    Expires: -1
    Server: Microsoft-IIS/8.0
    X-AspNet-Version: 4.0.30319
    X-SourceFiles: =?UTF-8?B?RTpcc3ZuXE1STV9SZXBvcnRzXE1ybU12Y1xhcGlccmVwb3J0c1xjbGllbnRz?=
    Persistent-Auth: true
    X-Powered-By: ASP.NET
    Date: Thu, 09 Oct 2014 18:25:39 GMT
    Content-Length: 1749
     
    {"Message":"An error has occurred.","ExceptionMessage":"Could not load file or assembly 'System.Net.Http.Formatting, Version=4.0.0.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35' or one of its dependencies. The located assembly's manifest definition does not match the assembly reference. (Exception from HRESULT: 0x80131040)","ExceptionType":"System.IO.FileLoadException","StackTrace":"   at Telerik.Reporting.Services.WebApi.ReportsExceptionFilter.OnException(HttpActionExecutedContext context)\r\n   at System.Web.Http.Filters.ExceptionFilterAttribute.OnExceptionAsync(HttpActionExecutedContext actionExecutedContext, CancellationToken cancellationToken)\r\n--- End of stack trace from previous location where exception was thrown ---\r\n   at System.Runtime.CompilerServices.TaskAwaiter.ThrowForNonSuccess(Task task)\r\n   at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)\r\n   at System.Web.Http.Filters.ExceptionFilterAttribute.<ExecuteExceptionFilterAsyncCore>d__0.MoveNext()\r\n--- End of stack trace from previous location where exception was thrown ---\r\n   at System.Runtime.CompilerServices.TaskAwaiter.ThrowForNonSuccess(Task task)\r\n   at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)\r\n   at System.Web.Http.Controllers.ExceptionFilterResult.<ExecuteAsync>d__0.MoveNext()\r\n--- End of stack trace from previous location where exception was thrown ---\r\n   at System.Runtime.CompilerServices.TaskAwaiter.ThrowForNonSuccess(Task task)\r\n   at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)\r\n   at System.Web.Http.Dispatcher.HttpControllerDispatcher.<SendAsync>d__0.MoveNext()"}
  4. Jan
    Jan avatar
    8 posts
    Member since:
    Sep 2014

    Posted 09 Oct 2014 in reply to Jan Link to this post

    I'll answer my own question here for the sake of any others... I had to update WebApi. The application was using version 5.1 and once I updated to 5.2.2 things started working.
Back to Top