View Issue Details
| ID | Project | Category | View Status | Date Submitted | Last Update |
|---|---|---|---|---|---|
| 0002727 | NoesisGUI | Unity | public | 2023-10-13 18:25 | 2024-07-05 20:26 |
| Reporter | stonstad | Assigned To | sfernandez | ||
| Priority | normal | Severity | crash | ||
| Status | resolved | Resolution | fixed | ||
| Product Version | 3.2.2 | ||||
| Target Version | 3.2.5 | ||||
| Summary | 0002727: Stack Overflow and Crash from Player and Unity Editor When Button Clicked | ||||
| Description | Clicking certain buttons causes both the Unity Editor and built Player to crash due to a stack overflow. The only change is that we upgraded to 3.2.2. I am not seeing a crash dump or error logs. When attached to the Editor process, I am getting this error: (Filename: D:/Source/StellarConquest/StellarConquest.Utilities/Noesis/3.2.2/Runtime/NoesisUnity.cs Line: 363) I am enclosing a minidump w/ heap from Visual Studio (when attached to Unity editor). Please let me know what else I can do to assist. | ||||
| Attached Files | |||||
| Platform | Any | ||||
| related to | 0002791 | resolved | sfernandez | [NOESIS/E] Visuals don't have a common ancestor after domain reload. |
| related to | 0002793 | resolved | sfernandez | Noesis Unloading UserControls |
|
Top of stack trace. |
|
|
If I hit continue in the debugger, it starts reading invalid memory.... nhandled exception at 0x00007FFD65FAC121 (Noesis.dll) in Unity.exe: 0xC0000005: Access violation writing location 0x00000066168D0FF0. Exception thrown at 0x00007FFD65FAC121 (Noesis.dll) in Unity.exe: 0xC0000005: Access violation writing location 0x00000066168D0FF0. Unhandled exception at 0x00007FFD65FAC121 (Noesis.dll) in Unity.exe: 0xC0000005: Access violation writing location 0x00000066168D0FF0. Exception thrown at 0x00007FFD65FAC121 (Noesis.dll) in Unity.exe: 0xC0000005: Access violation writing location 0x00000066168D0FF0. Unhandled exception at 0x00007FFD65FAC121 (Noesis.dll) in Unity.exe: 0xC0000005: Access violation writing location 0x00000066168D0FF0. Exception thrown at 0x00007FFD65FAC121 (Noesis.dll) in Unity.exe: 0xC0000005: Access violation writing location 0x00000066168D0FF0. Unhandled exception at 0x00007FFD65FAC121 (Noesis.dll) in Unity.exe: 0xC0000005: Access violation writing location 0x00000066168D0FF0. Exception thrown at 0x00007FFD65FAC121 (Noesis.dll) in Unity.exe: 0xC0000005: Access violation writing location 0x00000066168D0FF0. Unhandled exception at 0x00007FFD65FAC121 (Noesis.dll) in Unity.exe: 0xC0000005: Access violation writing location 0x00000066168D0FF0. Exception thrown at 0x00007FFD65FAC121 (Noesis.dll) in Unity.exe: 0xC0000005: Access violation writing location 0x00000066168D0FF0. Unhandled exception at 0x00007FFD65FAC121 (Noesis.dll) in Unity.exe: 0xC0000005: Access violation writing location 0x00000066168D0FF0. Exception thrown at 0x00007FFD65FAC121 (Noesis.dll) in Unity.exe: 0xC0000005: Access violation writing location 0x00000066168D0FF0. Unhandled exception at 0x00007FFD65FAC121 (Noesis.dll) in Unity.exe: 0xC0000005: Access violation writing location 0x00000066168D0FF0. Exception thrown at 0x00007FFD65FAC121 (Noesis.dll) in Unity.exe: 0xC0000005: Access violation writing location 0x00000066168D0FF0. Unhandled exception at 0x00007FFD65FAC121 (Noesis.dll) in Unity.exe: 0xC0000005: Access violation writing location 0x00000066168D0FF0. |
|
|
I can't reliably reproduce it. Clicking on buttons may cause the stack overflow. Because it is not consistent and I'm having trouble isolating it to a single line of code. This is high priority for me because if I can't get the PC version to run OK, I have to roll back to 3.2.1, and that impacts XBOX work, which has the corrupt texture issue in 3.2.1. |
|
|
I'm not able to open the attached crash dumps. Could you open them fine in your Visual? Which version? |
|
|
They came from VS 2022 17.5.2. I tried opening them and they don't work for me either. :( I kept getting VS errors when I tried to save dump. Assuming that is still broken, when retesting with PDBs help? |
|
|
I don't think PDBs will help. Let's try again to generate dumps. because without them we are unable to get enough information. I also assume you are not able to reproduce this in our Buttons example right? |
|
|
Understood. I'm working to understand why VS isn't properly exporting dumps. That's correct -- the button sample does not reproduce this behavior. |
|
|
Thanks! |
|
|
Still working on getting a dump exported. I keep getting an error message. I receive this error when I export from Unity and the built binary.... I'll try changing VS versions. |
|
|
Thanks for the dump! @Sergio This is seems to be related to an infinite loop generating offscreen nodes for visual brushes
|
|
|
If you have any test assemblies you would like us to try, we are ready and available. Or if there is a proposed work-around, thank you! |
|
|
Separately, we're seeing a hang when the game launches on Xbox and the build is release/master. We're thinking it could be related to the above behavior. Thanks, |
|
|
Good afternoon. I'm just reaching out to see if there are any updates? Thank you. |
|
|
Hello, we haven't had time to work on this |
|
|
How can I help to provide the diagnostic data needed to resolve this behavior? This bug prevents us from upgrading to 3.2.2. 3.2.1 is showing texture issues on Xbox and we are stuck between two worlds. Thanks, Shaun. |
|
|
Right now, we have all the needed information, we will come back as soon as possible. By the way, 3.2.1 should work in Xbox is you disable "Linear" rendering. |
|
|
Understood. Switching to gamma rendering creates a different set of problems for us. If the issue is related to visual brushes, perhaps I can arrange my XAML resourced dictionaries differently? |
|
|
Hi, The crash is definitely related to VisualBrushes. In the meantime could you please check your usage of VisualBrushes and maybe disable them? |
|
|
Your feedback as helpful. OK, the cause is the use of BackgroundEffectBehavior (shown in style below) in combination with a pop-up window. Usage is shown below the style. <Style x:Key="BorderControlHero" TargetType="local:BorderControlHero">
<!-- disabled to prevent stackoverflow behavior in 3.2.2 -->
</Style> _BackgroundBlurSource is created as a top-level element within the game's visual tree: <!-- game's top level visual tree --> <Grid> _BackgroundBlurSource and OverlayLayer exist within separate trees to prevent a stackoverflow. This works successfully in 3.2.1. |
|
|
It works in 3.2.1 all the time. And in 3.2.2 it works most of the time. When it fails, I am not seeing my code in the call stack. I am thinking this is a Noesis race condition. |
|
The visual result is as follows:
It works well except in 3.2.2 sometimes. |
|
|
I don't really understand what is happening or why. I may not share more detail for a while until I can understand what is happening. |
|
|
I can stop the crashes by disabling the visual brush used by BackgroundEffectBehavior. After careful analysis I do not believe there is a cyclic dependency with visual brushes. With the functionality disabled, I'm now seeing other behaviors during subsequent rounds of editor playback. The strange behaviors are resolved by an app domain reload. Some of these behaviors are documented in https://www.noesisengine.com/bugs/view.php?id=2791 and https://www.noesisengine.com/bugs/view.php?id=2793 Other behaviors are visual, such as UIs appearing differently based on the order of invocation within the visual tree. If there truly was a cyclic dependency in visual brushes, wouldn't 3.2.1, by necessity, also experience a stack overflow? I think the process for reloading app domains in Noesis changed. |
|
|
If this error was not happening always it might be related to your other posts 0002791 and 0002793. |
|
|
The previously described crash behavior is now resolved by changing the binding approach. Previously, binding BackgroundEffectBehavior.Source was accomplished as follows: // code-behind: public static readonly DependencyProperty BlurLayerProperty = DependencyProperty.Register("BlurLayer", typeof(FrameworkElement), typeof(BorderControlTitle), new PropertyMetadata(null)); public FrameworkElement BlurLayer public override void OnApplyTemplate()
} Binding is now accomplished as follows: public static readonly DependencyProperty BlurLayerProperty = DependencyProperty.Register("BlurLayer", typeof(FrameworkElement), typeof(BorderControlTitle), new PropertyMetadata(null)); public FrameworkElement BlurLayer // XAML: All error messages and crashes are now resolved. |
|
|
Can we close this issue? |
|
|
Yes, please feel free to close. Thank you for the assistance in resolving this behavior. |
|
| Date Modified | Username | Field | Change |
|---|---|---|---|
| 2023-10-13 18:25 | stonstad | New Issue | |
| 2023-10-13 18:25 | stonstad | File Added: Unity.dmp | |
| 2023-10-13 18:30 | stonstad | Note Added: 0008817 | |
| 2023-10-13 18:30 | stonstad | File Added: image.png | |
| 2023-10-13 18:32 | stonstad | Note Added: 0008818 | |
| 2023-10-13 18:32 | stonstad | File Added: Unity2.dmp | |
| 2023-10-13 18:49 | stonstad | Note Added: 0008820 | |
| 2023-10-16 17:52 | sfernandez | Assigned To | => sfernandez |
| 2023-10-16 17:52 | sfernandez | Status | new => assigned |
| 2023-10-16 17:52 | sfernandez | Target Version | => 3.2.3 |
| 2023-10-16 18:27 | sfernandez | Status | assigned => feedback |
| 2023-10-16 18:27 | sfernandez | Note Added: 0008828 | |
| 2023-10-16 18:33 | stonstad | Note Added: 0008829 | |
| 2023-10-16 18:33 | stonstad | Status | feedback => assigned |
| 2023-10-16 20:58 | jsantos | Note Added: 0008835 | |
| 2023-10-16 20:59 | jsantos | Status | assigned => feedback |
| 2023-10-18 17:04 | stonstad | Note Added: 0008843 | |
| 2023-10-18 17:04 | stonstad | Status | feedback => assigned |
| 2023-10-18 17:16 | jsantos | Status | assigned => feedback |
| 2023-10-18 17:16 | jsantos | Note Added: 0008844 | |
| 2023-10-18 17:58 | stonstad | Note Added: 0008845 | |
| 2023-10-18 17:58 | stonstad | File Added: image-2.png | |
| 2023-10-18 17:58 | stonstad | Status | feedback => assigned |
| 2023-10-18 17:58 | stonstad | Note Edited: 0008845 | |
| 2023-10-19 11:07 | jsantos | Note Added: 0008850 | |
| 2023-10-19 11:08 | jsantos | Note Edited: 0008850 | |
| 2023-10-20 21:07 | stonstad | Note Added: 0008860 | |
| 2023-10-20 21:18 | stonstad | Note Added: 0008861 | |
| 2023-10-23 14:30 | stonstad | Note Added: 0008864 | |
| 2023-10-23 14:53 | jsantos | Note Added: 0008865 | |
| 2023-10-24 20:14 | stonstad | Note Added: 0008877 | |
| 2023-10-25 11:48 | jsantos | Note Added: 0008881 | |
| 2023-10-26 16:17 | stonstad | Note Added: 0008884 | |
| 2023-10-27 21:11 | sfernandez | Note Edited: 0008850 | |
| 2023-10-27 21:23 | sfernandez | Status | assigned => feedback |
| 2023-10-27 21:23 | sfernandez | Note Added: 0008891 | |
| 2023-10-28 00:43 | stonstad | Note Added: 0008892 | |
| 2023-10-28 00:43 | stonstad | Status | feedback => assigned |
| 2023-10-28 17:43 | stonstad | Note Added: 0008893 | |
| 2023-10-28 17:44 | stonstad | Note Edited: 0008893 | |
| 2023-10-28 18:13 | stonstad | Note Added: 0008894 | |
| 2023-10-28 18:13 | stonstad | File Added: Base Layer Blur With Secondary Blur-.png | |
| 2023-10-28 18:13 | stonstad | File Added: Base Layer Blur.png | |
| 2023-10-28 18:54 | stonstad | Note Added: 0008895 | |
| 2023-10-28 19:14 | stonstad | Note Edited: 0008895 | |
| 2023-10-30 06:11 | stonstad | Note Added: 0008899 | |
| 2023-10-30 11:40 | sfernandez | Status | assigned => feedback |
| 2023-10-30 11:40 | sfernandez | Note Added: 0008901 | |
| 2023-10-30 11:42 | jsantos | Relationship added | related to 0002791 |
| 2023-10-30 11:42 | jsantos | Relationship added | related to 0002793 |
| 2023-10-30 17:41 | stonstad | Note Added: 0008908 | |
| 2023-10-30 17:41 | stonstad | Status | feedback => assigned |
| 2024-01-22 11:47 | sfernandez | Target Version | 3.2.3 => 3.2.4 |
| 2024-06-03 19:59 | sfernandez | Status | assigned => feedback |
| 2024-06-03 19:59 | sfernandez | Note Added: 0009620 | |
| 2024-06-13 18:01 | sfernandez | Target Version | 3.2.4 => 3.2.5 |
| 2024-07-05 19:36 | stonstad | Note Added: 0009746 | |
| 2024-07-05 19:36 | stonstad | Status | feedback => assigned |
| 2024-07-05 20:26 | jsantos | Status | assigned => resolved |
| 2024-07-05 20:26 | jsantos | Resolution | open => fixed |
| 2025-10-10 13:29 | jsantos | Category | Unity3D => Unity |