Base solution for your next web application
Open Closed

Visual Studio 2015 can`t start app debug #749

byteplatz created

Hello guys,

I am having issues frequently when trying to debug an AspNetZero project.

We are using VS2015 and latest version of AspNetZero.

First time we debug the solution using F5 everything works normal. Then we stop debugging and make some code changes in order to fix/add something. We hit F5 again and the debugger starts, browser opens and the output window is filled with information until we can see the messages generating DynamicProxyGenAssembly2 (Castle proxies) and it stays there forever. Browser keeps loading (spinning wheel) and debug output shows nothing. No exception at all (even marking all exceptions to be break into in ExceptionSettings).

I don't know what else to investigate.

Does anyone have the same issue ?

Does anyone uses VS2015 with Abp and debug / stop / change code / debug again and it works normal ?

I'm using IIS Express. The only thing left for tests is to use normal IIS instead of express...

Thanks a lot and hope someone can help me out with this.


6 Answer(s)
  • 0
    hikalkan created
    Support Team

    It's very strange. Because, we are using VS 2015 with AspNet Zero and it works properly. I tested as you said and works normally. Do you see anything in Web\Logs? You can try to change customErrors = "Off" in web.config, this may help to see ASP.NET level errors.

  • 0
    hikalkan created
    Support Team


    As I tested more, you're right. There is a problem. It's very strange but probably it's a problem of .Net framework when you create a MemoryCache on application start (ABP does it). You can find more explanation here: <a class="postlink" href=""> ... aracetamol</a>

    But, as a short solution, copy this code to your web project:

    /* Got from here:
        public static class ThreadCultureSanitizer
            public static void SanitizeThreadCulture()
                var currentCulture = CultureInfo.CurrentCulture;
                // at the top of any culture should be the invariant culture,
                // find it doing an .Equals comparison ensure that we will
                // find it and not loop endlessly
                var invariantCulture = currentCulture;
                while (invariantCulture.Equals(CultureInfo.InvariantCulture) == false)
                    invariantCulture = invariantCulture.Parent;
                if (ReferenceEquals(invariantCulture, CultureInfo.InvariantCulture))
                var thread = Thread.CurrentThread;
                thread.CurrentCulture = CultureInfo.GetCultureInfo(thread.CurrentCulture.Name);
                thread.CurrentUICulture = CultureInfo.GetCultureInfo(thread.CurrentUICulture.Name);

    Then call ThreadCultureSanitizer.SanitizeThreadCulture(); from 2 places:

    1. In global.asax file, as first line in Application_Start method.
    2. In Startup.cs, as first line in Configuration method.

    Then close all VS instances and open your project again.

    Please let me know if this works for you.

    Thanks, Have a nice day.

  • 0
    andmattia created

    Great post!!!

    I have the same issue but I supposted that relative to my WIN10... My work around was task manager -> IIS process -> kill but it's not very elegant!

    Nice work!


  • 0
    daws created

    Had the same stuff for weeks ... I was going to throw my computer out of the window :lol:

    Thanks for the investigation ;)

  • 0
    hikalkan created
    Support Team

    This will be built-in to ABP with v0.8 release. See <a class="postlink" href=""> ... issues/851</a> to adapt it.

  • 0
    byteplatz created

    Thanks a lot Halil,

    I will try your suggested solution

    Thanks again