Bug 39344 - VS becomes very unresponsive when working with a template forms project and one of the Windows projects is the startup
Summary: VS becomes very unresponsive when working with a template forms project and o...
Status: RESOLVED FIXED
Alias: None
Product: Visual Studio Extensions
Classification: Xamarin
Component: Xamarin.Forms ()
Version: 4.0.0 (C6)
Hardware: PC Windows
: Normal normal
Target Milestone: 4.4.0 (C10)
Assignee: Bugzilla
URL:
Depends on:
Blocks:
 
Reported: 2016-03-04 01:53 UTC by Jon Goldberger [MSFT]
Modified: 2017-06-28 17:31 UTC (History)
7 users (show)

Tags:
Is this bug a regression?: ---
Last known good build:


Attachments
XVS logs (346.60 KB, application/zip)
2016-03-04 01:56 UTC, Jon Goldberger [MSFT]
Details


Notice (2018-05-24): bugzilla.xamarin.com is now in read-only mode.

Please join us on Visual Studio Developer Community and in the Xamarin and Mono organizations on GitHub to continue tracking issues. Bugzilla will remain available for reference in read-only mode. We will continue to work on open Bugzilla bugs, copy them to the new locations as needed for follow-up, and add the new items under Related Links.

Our sincere thanks to everyone who has contributed on this bug tracker over the years. Thanks also for your understanding as we make these adjustments and improvements for the future.


Please create a new report on Developer Community with your current version information, steps to reproduce, and relevant error messages or log files if you are hitting an issue that looks similar to this resolved bug and you do not yet see a matching new report.

Related Links:
Status:
RESOLVED FIXED

Description Jon Goldberger [MSFT] 2016-03-04 01:53:27 UTC
## Description

After creating a new Forms project in Visual Studio, if I select any of the Windows app project as the startup project, VS becomes very unresponsive, to the point of being unusable, when editing files, or really doing just about anything. Issue does not occur if the iOS or Android project is the startup project. Also if a Windows project is the startup and you disconnect from the mac build host, the issue almost goes away (still seems a tiny bit sluggish, but almost negligible). 

In the screen cast below, I am simply going to edit the open file by deleting and re-adding a quotation mark. I will first show with iOS project as startup. 

Screencast: http://screencast.com/t/WXgo3MGv

Note that when you see me moving the cursor around after switching to the UWP project, I am actually clicking. You can see Vs become unresponsive with the activity circle and the UI dimming. 

Also note I am unsure what to file this against, customer who reported the issue said it only occurs with Forms solutions, but it is only Forms solutions that have the Windows app projects. Hence I am filing it against VS Extensions with Forms as the component. Feel free to change as need be. 

The reporting customer notes that he profiled VS when this was occurring and noticed a lot of time spent in SSH, hence why he tried disconnecting from the Mac BuIld host. 


## Steps to reproduce

1. Open Visual Studio (tested with VS 2015 on Windows 10) and create a new Forms PCL solution.

2. Change the start up project to the UWP (or other Windows) project.

3. Try editing a file. 

Expected result: VS will remain responsive.

Actual result: VS consistently hangs to an unusable degree. It will eventually become responsive again, but will become unresponsive again after any simple edit, or even just clicking somewhere in the file to move the cursor.


## Environment

Microsoft Visual Studio Professional 2015
Version 14.0.23107.0 D14REL
Microsoft .NET Framework
Version 4.6.01038

Installed Version: Professional

Visual Basic 2015   00322-40000-00000-AA850
Microsoft Visual Basic 2015

Visual C# 2015   00322-40000-00000-AA850
Microsoft Visual C# 2015

Visual C++ 2015   00322-40000-00000-AA850
Microsoft Visual C++ 2015

Visual F# 2015 RC   00322-40000-00000-AA850
Microsoft Visual F# 2015 RC

Windows Phone SDK 8.0 - ENU   00322-40000-00000-AA850
Windows Phone SDK 8.0 - ENU

Application Insights Tools for Visual Studio Package   1.0
Application Insights Tools for Visual Studio

ASP.NET and Web Tools   14.0.20626.0
ASP.NET and Web Tools

ASP.NET Web Frameworks and Tools 2013   5.2.30624.0
For additional information, visit http://www.asp.net/

Common Azure Tools   1.5
Provides common services for use by Azure Mobile Services and Microsoft Azure Tools.

GenerateUnitTest   1.0
Generates unit test code for methods in classes under test.

GitHub.VisualStudio   1.0
A Visual Studio Extension that brings the GitHub Flow into Visual Studio.

Microsoft Azure Mobile Services Tools   1.4
Microsoft Azure Mobile Services Tools

NuGet Package Manager   3.2.0
NuGet Package Manager in Visual Studio. For more information about NuGet, visit http://docs.nuget.org/.

PreEmptive Analytics Visualizer   1.2
Microsoft Visual Studio extension to visualize aggregated summaries from the PreEmptive Analytics product.

SQL Server Data Tools   14.0.50616.0
Microsoft SQL Server Data Tools

Visual Studio Tools for Universal Windows Apps   14.0.23309.00 d14oob
The Visual Studio Tools for Universal Windows apps allow you to build a single universal app experience that can reach every device running Windows 10: phone, tablet, PC, and more. It includes the Microsoft Windows 10 Software Development Kit.

Xamarin   4.0.1.96 (dcea9c1)
Visual Studio extension to enable development for Xamarin.iOS and Xamarin.Android.

Xamarin.Android   6.0.1.10 (e98e962)
Visual Studio plugin to enable development for Xamarin.Android.

Xamarin.iOS   9.4.1.24 (47eb74b)
Visual Studio extension to enable development for Xamarin.iOS.
Comment 2 Jon Goldberger [MSFT] 2016-03-04 01:56:36 UTC
Created attachment 15250 [details]
XVS logs
Comment 3 Brendan Zagaeski (Xamarin Team, assistant) 2016-03-04 20:08:27 UTC
For bookkeeping I will note that there's chance the fix for this bug (Bug 39344) might also resolve non-public Bug 37170.
Comment 4 Brendan Zagaeski (Xamarin Team, assistant) 2016-03-04 20:12:07 UTC
> if ... you disconnect from the mac build host, the issue almost goes away

As an additional cross-reference, this particular detail sounds similar to Bug 39285.
Comment 5 Daniel R. Regner 2016-05-14 00:35:38 UTC
I am seeing what appears to be the same IDE unresponsiveness issues when connected to an iOS build host (and the solution does contain Windows projects).  After attaching a second instance of VS2015 to troubleshoot, I see a large number of threads (what looks like an unbounded number of threads being spawned) throwing ArgumentExceptions trying to look up the "Info.plist" file in the project item collection for projects that contain no such file.  The UI thread is not completely blocked and appears to still be processing messages slowly, but the CPU is pegged as this code path is running repeatedly.


	Exception: Exception thrown: 'System.ArgumentException' in Xamarin.VisualStudio.IOS.Common.dll ("Value does not fall within the expected range."). Exception thrown: 'System.ArgumentException' in Xamarin.VisualStudio.IOS.Common.dll ("Value does not fall within the expected range.")

 	Xamarin.VisualStudio.IOS.Common.dll!Xamarin.VisualStudio.IOS.PlistDocumentManager.GetInfoPlistPath(EnvDTE.Project project)	Unknown
 	Xamarin.VisualStudio.IOS.Common.dll!Xamarin.VisualStudio.IOS.PlistDocumentManager.GetInfoPlist(EnvDTE.Project project)	Unknown
 	Xamarin.VisualStudio.IOS.Common.dll!EnvDTE.DteProjectExtensions.IsMonoTouchWatchKitAppExtensionProject(EnvDTE.Project project)	Unknown
 	Xamarin.VisualStudio.IOS.dll!Xamarin.VisualStudio.IOS.MonoTouchDevice.AppliesTo(Clide.Solution.IProjectNode project, Xamarin.VisualStudio.Devices.DeviceFilteringOptions options) Line 115	C#
 	Xamarin.VisualStudio.Devices.dll!Xamarin.VisualStudio.Devices.Device.IsUnsupportedFor(Clide.Solution.IProjectNode project) Line 42	C#
 	Xamarin.VisualStudio.IOS.dll!Xamarin.VisualStudio.IOS.MonoTouchDevice.IsUnsupportedFor(Clide.Solution.IProjectNode project) Line 258	C#
 	Xamarin.VisualStudio.Devices.dll!Xamarin.VisualStudio.Devices.XamarinProjectCfgDebugTargetSelection.UpdateDevicesAsync.AnonymousMethod__32_0() Line 269	C#
 	[Resuming Async Method]	
 	mscorlib.dll!System.Runtime.CompilerServices.AsyncMethodBuilderCore.MoveNextRunner.InvokeMoveNext(object stateMachine)	Unknown
 	mscorlib.dll!System.Threading.ExecutionContext.RunInternal(System.Threading.ExecutionContext executionContext, System.Threading.ContextCallback callback, object state, bool preserveSyncCtx)	Unknown
 	mscorlib.dll!System.Threading.ExecutionContext.Run(System.Threading.ExecutionContext executionContext, System.Threading.ContextCallback callback, object state, bool preserveSyncCtx)	Unknown
 	mscorlib.dll!System.Runtime.CompilerServices.AsyncMethodBuilderCore.MoveNextRunner.Run()	Unknown
 	mscorlib.dll!System.Runtime.CompilerServices.AsyncMethodBuilderCore.OutputAsyncCausalityEvents.AnonymousMethod__0()	Unknown
 	mscorlib.dll!System.Runtime.CompilerServices.AsyncMethodBuilderCore.ContinuationWrapper.Invoke()	Unknown
 	mscorlib.dll!System.Runtime.CompilerServices.TaskAwaiter.OutputWaitEtwEvents.AnonymousMethod__0()	Unknown
 	mscorlib.dll!System.Runtime.CompilerServices.AsyncMethodBuilderCore.ContinuationWrapper.Invoke()	Unknown
 	mscorlib.dll!System.Threading.Tasks.AwaitTaskContinuation.RunOrScheduleAction(System.Action action, bool allowInlining, ref System.Threading.Tasks.Task currentTask)	Unknown
 	mscorlib.dll!System.Threading.Tasks.Task.FinishContinuations()	Unknown
 	mscorlib.dll!System.Threading.Tasks.Task.FinishStageThree()	Unknown
 	mscorlib.dll!System.Threading.Tasks.Task<bool>.TrySetResult(bool result)	Unknown
 	mscorlib.dll!System.Runtime.CompilerServices.AsyncTaskMethodBuilder<bool>.SetResult(bool result)	Unknown
>	Xamarin.VisualStudio.IOS.dll!Xamarin.VisualStudio.IOS.MonoTouchDevice.AppliesToAsync(Clide.Solution.IProjectNode project, Xamarin.VisualStudio.Devices.DeviceFilteringOptions options) Line 254	C#
 	[Resuming Async Method]	
 	mscorlib.dll!System.Runtime.CompilerServices.AsyncMethodBuilderCore.MoveNextRunner.InvokeMoveNext(object stateMachine)	Unknown
 	mscorlib.dll!System.Threading.ExecutionContext.RunInternal(System.Threading.ExecutionContext executionContext, System.Threading.ContextCallback callback, object state, bool preserveSyncCtx)	Unknown
 	mscorlib.dll!System.Threading.ExecutionContext.Run(System.Threading.ExecutionContext executionContext, System.Threading.ContextCallback callback, object state, bool preserveSyncCtx)	Unknown
 	mscorlib.dll!System.Runtime.CompilerServices.AsyncMethodBuilderCore.MoveNextRunner.Run()	Unknown
 	mscorlib.dll!System.Runtime.CompilerServices.AsyncMethodBuilderCore.OutputAsyncCausalityEvents.AnonymousMethod__0()	Unknown
 	mscorlib.dll!System.Runtime.CompilerServices.AsyncMethodBuilderCore.ContinuationWrapper.Invoke()	Unknown
 	mscorlib.dll!System.Runtime.CompilerServices.TaskAwaiter.OutputWaitEtwEvents.AnonymousMethod__0()	Unknown
 	mscorlib.dll!System.Runtime.CompilerServices.AsyncMethodBuilderCore.ContinuationWrapper.Invoke()	Unknown
 	mscorlib.dll!System.Threading.Tasks.AwaitTaskContinuation.RunOrScheduleAction(System.Action action, bool allowInlining, ref System.Threading.Tasks.Task currentTask)	Unknown
 	mscorlib.dll!System.Threading.Tasks.Task.FinishContinuations()	Unknown
 	mscorlib.dll!System.Threading.Tasks.Task.FinishStageThree()	Unknown
 	mscorlib.dll!System.Threading.Tasks.Task<System.__Canon>.TrySetResult(System.__Canon result)	Unknown
 	mscorlib.dll!System.Runtime.CompilerServices.AsyncTaskMethodBuilder<Xamarin.MacDev.PDictionary>.SetResult(Xamarin.MacDev.PDictionary result)	Unknown
 	Xamarin.VisualStudio.IOS.Common.dll!EnvDTE.DteProjectExtensions.GetInfoPlistAsync(EnvDTE.Project project)	Unknown
 	mscorlib.dll!System.Runtime.CompilerServices.AsyncMethodBuilderCore.MoveNextRunner.InvokeMoveNext(object stateMachine)	Unknown
 	mscorlib.dll!System.Threading.ExecutionContext.RunInternal(System.Threading.ExecutionContext executionContext, System.Threading.ContextCallback callback, object state, bool preserveSyncCtx)	Unknown
 	mscorlib.dll!System.Threading.ExecutionContext.Run(System.Threading.ExecutionContext executionContext, System.Threading.ContextCallback callback, object state, bool preserveSyncCtx)	Unknown
 	mscorlib.dll!System.Runtime.CompilerServices.AsyncMethodBuilderCore.MoveNextRunner.Run()	Unknown
 	mscorlib.dll!System.Runtime.CompilerServices.AsyncMethodBuilderCore.OutputAsyncCausalityEvents.AnonymousMethod__0()	Unknown
 	mscorlib.dll!System.Runtime.CompilerServices.AsyncMethodBuilderCore.ContinuationWrapper.Invoke()	Unknown
 	mscorlib.dll!System.Runtime.CompilerServices.TaskAwaiter.OutputWaitEtwEvents.AnonymousMethod__0()	Unknown
 	mscorlib.dll!System.Runtime.CompilerServices.AsyncMethodBuilderCore.ContinuationWrapper.Invoke()	Unknown
 	mscorlib.dll!System.Threading.Tasks.AwaitTaskContinuation.RunOrScheduleAction(System.Action action, bool allowInlining, ref System.Threading.Tasks.Task currentTask)	Unknown
 	mscorlib.dll!System.Threading.Tasks.Task.FinishContinuations()	Unknown
 	mscorlib.dll!System.Threading.Tasks.Task.FinishStageThree()	Unknown
 	mscorlib.dll!System.Threading.Tasks.Task<System.__Canon>.TrySetResult(System.__Canon result)	Unknown
 	mscorlib.dll!System.Runtime.CompilerServices.AsyncTaskMethodBuilder<Xamarin.MacDev.PDictionary>.SetResult(Xamarin.MacDev.PDictionary result)	Unknown
 	Xamarin.VisualStudio.IOS.Common.dll!Xamarin.VisualStudio.IOS.PlistDocumentManager.GetInfoPlistAsync(EnvDTE.Project project)	Unknown
 	mscorlib.dll!System.Runtime.CompilerServices.AsyncMethodBuilderCore.MoveNextRunner.InvokeMoveNext(object stateMachine)	Unknown
 	mscorlib.dll!System.Threading.ExecutionContext.RunInternal(System.Threading.ExecutionContext executionContext, System.Threading.ContextCallback callback, object state, bool preserveSyncCtx)	Unknown
 	mscorlib.dll!System.Threading.ExecutionContext.Run(System.Threading.ExecutionContext executionContext, System.Threading.ContextCallback callback, object state, bool preserveSyncCtx)	Unknown
 	mscorlib.dll!System.Runtime.CompilerServices.AsyncMethodBuilderCore.MoveNextRunner.Run()	Unknown
 	mscorlib.dll!System.Runtime.CompilerServices.AsyncMethodBuilderCore.OutputAsyncCausalityEvents.AnonymousMethod__0()	Unknown
 	mscorlib.dll!System.Runtime.CompilerServices.AsyncMethodBuilderCore.ContinuationWrapper.Invoke()	Unknown
 	mscorlib.dll!System.Runtime.CompilerServices.TaskAwaiter.OutputWaitEtwEvents.AnonymousMethod__0()	Unknown
 	mscorlib.dll!System.Runtime.CompilerServices.AsyncMethodBuilderCore.ContinuationWrapper.Invoke()	Unknown
 	mscorlib.dll!System.Threading.Tasks.AwaitTaskContinuation.RunOrScheduleAction(System.Action action, bool allowInlining, ref System.Threading.Tasks.Task currentTask)	Unknown
 	mscorlib.dll!System.Threading.Tasks.Task.FinishContinuations()	Unknown
 	mscorlib.dll!System.Threading.Tasks.Task.FinishStageThree()	Unknown
 	mscorlib.dll!System.Threading.Tasks.Task<System.__Canon>.TrySetResult(System.__Canon result)	Unknown
 	mscorlib.dll!System.Runtime.CompilerServices.AsyncTaskMethodBuilder<string>.SetResult(string result)	Unknown
 	Xamarin.VisualStudio.IOS.Common.dll!Xamarin.VisualStudio.IOS.PlistDocumentManager.GetInfoPlistPathAsync(EnvDTE.Project project)	Unknown
 	mscorlib.dll!System.Runtime.CompilerServices.AsyncMethodBuilderCore.MoveNextRunner.InvokeMoveNext(object stateMachine)	Unknown
 	mscorlib.dll!System.Threading.ExecutionContext.RunInternal(System.Threading.ExecutionContext executionContext, System.Threading.ContextCallback callback, object state, bool preserveSyncCtx)	Unknown
 	mscorlib.dll!System.Threading.ExecutionContext.Run(System.Threading.ExecutionContext executionContext, System.Threading.ContextCallback callback, object state, bool preserveSyncCtx)	Unknown
 	mscorlib.dll!System.Runtime.CompilerServices.AsyncMethodBuilderCore.MoveNextRunner.Run()	Unknown
 	mscorlib.dll!System.Runtime.CompilerServices.AsyncMethodBuilderCore.OutputAsyncCausalityEvents.AnonymousMethod__0()	Unknown
 	mscorlib.dll!System.Runtime.CompilerServices.AsyncMethodBuilderCore.ContinuationWrapper.Invoke()	Unknown
 	mscorlib.dll!System.Runtime.CompilerServices.TaskAwaiter.OutputWaitEtwEvents.AnonymousMethod__0()	Unknown
 	mscorlib.dll!System.Runtime.CompilerServices.AsyncMethodBuilderCore.ContinuationWrapper.Invoke()	Unknown
 	mscorlib.dll!System.Threading.Tasks.AwaitTaskContinuation.RunOrScheduleAction(System.Action action, bool allowInlining, ref System.Threading.Tasks.Task currentTask)	Unknown
 	mscorlib.dll!System.Threading.Tasks.Task.FinishContinuations()	Unknown
 	mscorlib.dll!System.Threading.Tasks.Task.FinishStageThree()	Unknown
 	mscorlib.dll!System.Threading.Tasks.Task.FinishStageTwo()	Unknown
 	mscorlib.dll!System.Threading.Tasks.Task.Finish(bool bUserDelegateExecuted)	Unknown
 	mscorlib.dll!System.Threading.Tasks.Task.ExecuteWithThreadLocal(ref System.Threading.Tasks.Task currentTaskSlot)	Unknown
 	mscorlib.dll!System.Threading.Tasks.Task.ExecuteEntry(bool bPreventDoubleExecution)	Unknown
 	mscorlib.dll!System.Threading.Tasks.Task.System.Threading.IThreadPoolWorkItem.ExecuteWorkItem()	Unknown
 	mscorlib.dll!System.Threading.ThreadPoolWorkQueue.Dispatch()	Unknown
 	mscorlib.dll!System.Threading._ThreadPoolWaitCallback.PerformWaitCallback()	Unknown
 	[Async Call]	
 	Xamarin.VisualStudio.Devices.dll!Xamarin.VisualStudio.Devices.XamarinProjectCfgDebugTargetSelection.UpdateDevicesAsync() Line 251	C#
Comment 6 Joaquin Jares 2017-06-28 17:31:23 UTC
The issue here was with iOS simulators interfering with Windows projects. This is now fixed. Please feel free to reopen if you're still seeing this issue.