Copied to clipboard

Flag this post as spam?

This post will be reported to the moderators as potential spam to be looked at

  • Chris Van Oort 110 posts 370 karma points
    Jan 24, 2017 @ 21:12
    Chris Van Oort

    GetMailStatistics 500 error?

    I'm encountering a 500 error on the console in the back office when I click on the Emails nodes:

    enter image description here


    • Umbraco 7.5.7
    • Umbraco Forms 4.4.0
    • PerplexMail 2016-11-02

    Any ideas? Doesn't seem to be impacting email sending.


    I'm not sure if this is actually an issue; it only appears to be affecting my local development instance where I've uninstalled and reinstalled the extension several times.

  • Chris Van Oort 110 posts 370 karma points
    Jan 25, 2017 @ 20:55
    Chris Van Oort

    I upgraded to Umbraco 7.5.8 to solve another issue, and then dug into the code via Github.

    It looks like the proper MVC code that uses Umbraco.Web.WebApi is available in PerplexMailController.cs line 232 (

    However, it's commented out in favor of some code on line 31 in the same file. In Visual Studio, I'm getting the following warning, which may be why it's not working in Umbraco 7.5.7 or 7.5.8:

    Warning CS0618  'RestExtensionMethodAttribute' is obsolete: 'Umbraco /base is obsoleted, use WebApi (UmbracoApiController) instead for all REST based logic'    PerplexMail D:\Documents\Visual Studio Workspace\Libraries\PerplexMail\PerplexMail-for-Umbraco-master\PerplexMail\PerplexMailController.cs

    Any ideas?

  • Wouter van der Beek 20 posts 282 karma points
    Jan 31, 2017 @ 10:23
    Wouter van der Beek

    Hello Chris,

    Back when the package was originally created we decided to use the REST extension in favour of the ApiController-style approach to increase backwards compatibility and avoid issues with MVC library depencies . The current version of Umbraco still has the implementation of the class RestExtensionMethodAttribute (I'm assuming this will get removed by the time Umbraco 8.0 comes around), but for now it should still work.

    As far as the internal server error goes:

    • It would be helpful if you could provide any details regarding the error. If you are developing locally, could you open the chrome debugger and try refreshing the page. After that check the exact error the server is throwing back at you under the network tab. If that does not reveal anything, could you please go to your machine's Event Viewer and view the application error in question? This should at least reveal the exception details that your machine is running into.

    • It is also possible the package is having trouble reading the database table. You could try to create a backup of your database, and then throwing away the perplexLogMail and perplexLogMailStatistics tables, and then trying to see if the library regenerates the missing tables. You could also try renaming your tables if you don't want to create a backup, but be aware that the primary key name will also have to be renamed (otherwise you will stil get a database saying the primary key name has to be unique, even if you renamed the table).

  • Chris Van Oort 110 posts 370 karma points
    Mar 03, 2017 @ 19:19
    Chris Van Oort

    Hi Wouter,

    I got pulled off on another project, so I'm just now circling back on this. I just did an Umbraco upgrade today to 7.5.10 and I can't reproduce the issue. I did change the dependencyhandler in my web.config from "GET" to "*" as it was in the vanilla Umbraco install. (Unsure if related)

    I'd go ahead and mark this as a non-issue for now. Thanks!

  • John Logan 24 posts 65 karma points
    Mar 04, 2019 @ 11:24
    John Logan

    I came across this issue today and was getting the same 500 errors for the stats.

    When I was first using the package I was not getting this error so I knew it was something I added afterwards.

    The culprit was a rewrite rule: I had added an "add trailing slash" rewrite rule and this was what was causing the issue. Adding in a negate condition fixed the issue.

    Not sure if the cause is the same as OP but hopefully it may be related and will help

    Cheers J

Please Sign in or register to post replies

Write your reply to: