I have an ASP.Net MVC project that I have been working on for many months without incident. Since yesterday, the VS 2012 debugger consistently detaches from the project after it has been running for 2-3 minutes. So far, I cannot find any specific event that might trigger the detach.
I have not recently updated VS 2012 or any 3rd party libraries.
I can attach to the project again using Debug / Attach to Process. I have not observed the debugger detaching again after manually re-attaching.
When running a different, console program in the debugger I do not observe the same behavior.
How can I troubleshoot this issue?
Related
It seems like with VS 2019 (Enterprise?), there is a new type of console application host available that even stays unclosed after I stop debugging. When starting multiple projects, the first console application that starts up will be of this new type.
I am searching for a way to prevent VS to use this console for the "main"-project, and simply use the same console for every project I am starting. I have started the same solution with 4 ASP.NET Core projects inside VS 2017 and Visual Studio did not start any console with 'dotnet.exe' in the title. So for is seems like this is a new thing in 2019.
The reason for this question is because I am having some trouble with this new console. The project often does not start at all and the colors of the console are all green. But that shouldn't be topic of this question.
So is there a way to prevent Visual Studio 2019 from starting this new console?
There's a setting under Tools->Options->Debugging->Automatically close the console when debugging stops that will restore the old behavior.
Something really weird is happening with my installation of Visual Studio 2015. When I just opened VS and run the project, it deploys normally. However, when I start to change things i.e. html, js, etc and hit refresh to see my new changes, after a while the browser takes FOREVER to load the page again.
This also happens when I change server code, suppose the project is running normally, then I stop the debugger, change my code, and launch the project again.
I have Windows 10 installed in my machine, Visual Studio 2015 Update 1.
I don't know what could be happening, and I have googled it without much success. Does somebody know a way I could inspect what is happening when this occurs? Any tools?
I'm in the process of diagnosing this issue and I will update as I learn more but I wanted to post what I have in case there's a quick fix/someone's seen this already.
I have a MVC5 project, .NET 4.5.2, Visual Studio 2015. I recently started using C# 6 so in order to get Razor to work I had to install the CodeDOM compiler Nuget package. Everything works on my local machine (of course it does).
My current stable Azure site is on a Git commit that is NOT using C# 6, but is using .NET 4.5.2 and VS 2015. So the only big difference between my latest commit and the stable commit is the introduction of C# 6 and Roslyn.
When I deploy the new commit to Azure, I consistently get 502 Gateway errors after it spins for up to 2 minutes. On a MVC action that does NOT return a view but a Content action result, it will eventually return content although it's pretty slow. When I go to Kudu and view processes, I can see the Roslyn compiler runs and I was noticing last night that the w3wp process would restart every so often, usually after I get the 502 on requests.
If I redeploy my earlier commit, it works fine.
My next steps really are to isolate the issue to a blank web app using C# 6 and MVC 5, to see if that is the root cause--but my educated guess is the introduction of the Roslyn compiler is messing things up in Azure.
Anyone have any ideas? I'll update this as I learn more, but I have a busy day and weekend ahead.
Figured it out, slowly but surely, took me all day. I deployed each commit since the last stable one and found the commit that introduced the issue. In the commit I had introduced some more TypeScript files. Turns out these were NOT compiling in Kudu/Azure and so the JS files were missing, causing my bundling/minification framework (Cassette) to try to resolve references--which it never resolved and caused a StackOverflow or loop issue (separate bug) which caused my w3wp process to crash. This is why it was almost impossible to debug and also why my non-Razor actions returned--they weren't rendering the bundles so it didn't call into Cassette.
I included the generated JS files in the project and that fixed the problem. I think I will just edit my Kudu deployment script and call tsc manually on my tsconfig.json file so it compiles on build properly.
I have read other articles about performance issues in VS especially Why VS 2013 is very slow, and have performed every advice in this article, but nothing has changed. My VS Studio is running quickly when I am developing a Windows Application. But when I am working on a Web MVC Solution, it is extremely slow. Even simple typing is performed with delay and not only debuging etc.
How can I solve this issue? I have done the following steps:
1. Disabled the plugins (Git...)
2. Cleaned the cache and temporary files
3. Disabled Codelens
4. Disabled synchronization over multiple machines
5. Disabled the hardware graphic accelerations
But nothing has changed and even if I create a new MVC solution, the problem exists and even typing is performed with delay.
I would suggest to check the /Log (https://msdn.microsoft.com/en-us/library/ms241272.aspx) or check some tutorials (https://www.google.com/search?q=speed+up+visual+studio+2013). As a final resort you could try a fresh reinstall.
I have found the answer to this problem. You have to run the Update 4 RTM for VS 2013. After that the problem is solved.
I have an MVC 5 app running in Visual Studio 2014 Update 4.
My app is running fine in VS2013. But very often (about 4 out of 5 times) the debugger suddenly detaches from the process.
While the website keeps running, I don't get (of course) any debug information / breakpoints anymore.
Does someone have a solution or a way to troubleshoot this?