Page 1 of 3

Attempting to debug with Unity causes Unity to become non-responsive

Posted: 16 Mar 2017, 01:25
by XaeroDegreaz
I've tried debugging from Visual Studio 2015, and also Jetbrains "Rider". Both produce similar results -- the Unity editor becomes unresponsive and requires me to kill the process.

From Visual Studio, the lock up happens as soon as I hit play. From Rider, I was able to get the play to work, but as soon as I interacted with the UI it locked up.

I can send a test scene for you to test out if you can't reproduce it yourself.

Re: Attempting to debug with Unity causes Unity to become non-responsive

Posted: 16 Mar 2017, 05:36
by ai_enabled
What version of Unity and VS are you using?

That might be not related to NoesisGUI... are you checked this with projects without NoesisGUI?
We has this issue for long with Unity games, including games not using NoesisGUI.
These are known issues of the Unity tools for VS:
* When debugging, Unity sometimes crashes.
* When debugging, Unity sometimes freezes.
(see https://msdn.microsoft.com/en-us/library/dn940022.aspx )
Thought I don't know anything about Rider support for Unity.

Re: Attempting to debug with Unity causes Unity to become non-responsive

Posted: 17 Mar 2017, 02:13
by XaeroDegreaz
Yeah I can debug other projects fine. I could also debug this project fine before bringing in Noesis.

Using Unity 5.5.1, and VS 2015

Re: Attempting to debug with Unity causes Unity to become non-responsive

Posted: 17 Mar 2017, 02:27
by XaeroDegreaz
Just to double confirm, I tested by hitting a breakpoint using some other script. Then, I set a breakpoint on a Noesis script and it worked. Then, I stopped the player, and triggered the same Noesis breakpoint again and it locked up o_O

Not sure what the problem is. Looks like my workaround may be to trigger some breakpoint in another script somewhere first ?Lol

Re: Attempting to debug with Unity causes Unity to become non-responsive

Posted: 20 Mar 2017, 20:06
by sfernandez
Does this happen with a specific project?
Does even occur debugging a new project with just our package?

Re: Attempting to debug with Unity causes Unity to become non-responsive

Posted: 20 Mar 2017, 21:34
by monstercho
I also see this problem from time to time. Just now confirmed with new project:
1) Created new project and imported NoesisGUI 2
2) Opened the ControllGallery sample scene.
3) First try:
- put breakpoint at start of OnInitialized
- attach Visual Studio to Unity (F5)
- play in Unity - VS stops at the breakpoint - all OK so continue (F5)
- press stop play in Unity and detach VS (SHIFT+F5)
4) 2nd try immediately after the previous:
- remove the 1st breakpoint and put breakpoint at start of OnStyleSelectionChanged()
- attach VS to Unity (F5)
- play in Unity - Unity hangs
- try to detach VS (SHIFT+F5) - VS shows stop debugging in progress confirmation and I force stop
- Unity still not reacting - have to kill it from task manager

Using Unity 5.5.2f1 (64-bit) and VS2017.

From experience with another project - seems to happen only if there is a breakpoint enabled before pressing play in Unity (not always).

Re: Attempting to debug with Unity causes Unity to become non-responsive

Posted: 07 Apr 2017, 19:52
by vaninadisc
Same here =/. I haven't tried the exact repro steps posted above, but I can confirm that in my project I'm able to hit breakpoints outside of Noesis triggered code, but within Noesis I end up having to kill unity from taskmanager.

Unity 5.5.1f1 (32-bit), VS2017, Noesis 2.0.

Re: Attempting to debug with Unity causes Unity to become non-responsive

Posted: 08 Apr 2017, 06:14
by Zentropy
Confirming I have this same issue as well. It's definitely Noesis. Brand new project with nothing but Noesis and breakpoints in Noesis code lock Unity 90% of the time. I use breakpoints elsewhere constantly and have zero lockups at all. Trivially reproduceable by importing Noesis into a fresh project, opening the Button sample scene, then setting a breakpoint in Button.xaml.cs inside its InitializeComponent method and hitting Play in Unity

Re: Attempting to debug with Unity causes Unity to become non-responsive

Posted: 08 Apr 2017, 07:05
by nokola
I just started hitting this today too in my app project. Unity 5.6, Noesis 2.
I tried first Play then Attach or first Attach VS then Play in Unity. In both cases, Unity hangs up. I set the breakpoints in non-Noesis code.
I can't repro with clean project + Noesis, so not sure what causes the issue yet.

Re: Attempting to debug with Unity causes Unity to become non-responsive

Posted: 08 Apr 2017, 09:16
by monstercho
I also see it with breakpoints in non-Noesis code, so cannot be sure it's Noesis related.
Good thing is that after killing Unity and starting it again (not restarting VS) - same breakpoints work without hanging Unity.