Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Stride crashed while alt-tabbing from a script (in-engine editor) #2595

Open
WeeveFerrelaine opened this issue Jan 15, 2025 · 11 comments
Open

Comments

@WeeveFerrelaine
Copy link

Not entirely sure what the issue is, but I had a crash happen while I went from programming (in the in-engine code editor), and alt-tabbed to my file browser. When I had left off dev last, the script was not compiling, so I had opened stride with the warning that it failed to load the script, and then was just working on it for a little bit, before I needed to alt-tab, and experienced the crash. At no point was the script compilable during my dev sesh, so idk if it expected to find my script, and then when it wasn't there, just went kaput maybe?

Log:

message.txt

SS:

Image

@WeeveFerrelaine
Copy link
Author

I'm not sure if I tried to run the game during that sesh at all or not- I'm leaning towards no, so I'd have never tried to recompile. If it helps, the email I sent that report with was [email protected], if anyone has access to those reports, and wants to correlate my issue information to it

@Eideren Eideren transferred this issue from stride3d/stride-docs Jan 15, 2025
@Eideren
Copy link
Collaborator

Eideren commented Jan 15, 2025

Moved the issue to the engine repository, you were on the documentation one ;)

Here is the stacktrace contained in @WeeveFerrelaine 's txt for discoverability

Exception: NullReferenceException: Object reference not set to an instance of an object.
   at Stride.Core.Assets.Editor.Services.UserDocumentationService.ClearCachedAssemblyDocumentation(Assembly assembly) in C:\BuildAgent\work\b5f46e3c4829a09e\sources\editor\Stride.Core.Assets.Editor\Services\UserDocumentationService.cs:line 82
   at Stride.GameStudio.ViewModels.DebuggingViewModel.ReloadAssemblies() in C:\BuildAgent\work\b5f46e3c4829a09e\sources\editor\Stride.GameStudio\ViewModels\DebuggingViewModel.cs:line 259
   at Stride.Core.Presentation.Commands.AnonymousTaskCommand.<>c__DisplayClass0_0.<<-ctor>b__0>d.MoveNext() in C:\BuildAgent\work\b5f46e3c4829a09e\sources\presentation\Stride.Core.Presentation\Commands\AnonymousCommand.cs:line 84
--- End of stack trace from previous location ---
   at System.Threading.Tasks.Task.<>c.<ThrowAsync>b__128_0(Object state)
   at System.Windows.Threading.ExceptionWrapper.InternalRealCall(Delegate callback, Object args, Int32 numArgs)
   at System.Windows.Threading.ExceptionWrapper.TryCatchWhen(Object source, Delegate callback, Object args, Int32 numArgs, Delegate catchHandler)
   at System.Windows.Threading.DispatcherOperation.InvokeImpl()
   at MS.Internal.CulturePreservingExecutionContext.CallbackWrapper(Object obj)
   at System.Threading.ExecutionContext.RunInternal(ExecutionContext executionContext, ContextCallback callback, Object state)
--- End of stack trace from previous location ---
   at System.Threading.ExecutionContext.RunInternal(ExecutionContext executionContext, ContextCallback callback, Object state)
   at MS.Internal.CulturePreservingExecutionContext.Run(CulturePreservingExecutionContext executionContext, ContextCallback callback, Object state)
   at System.Windows.Threading.DispatcherOperation.Invoke()
   at System.Windows.Threading.Dispatcher.ProcessQueue()
   at System.Windows.Threading.Dispatcher.WndProcHook(IntPtr hwnd, Int32 msg, IntPtr wParam, IntPtr lParam, Boolean& handled)
   at MS.Win32.HwndWrapper.WndProc(IntPtr hwnd, Int32 msg, IntPtr wParam, IntPtr lParam, Boolean& handled)
   at System.Windows.Threading.ExceptionWrapper.InternalRealCall(Delegate callback, Object args, Int32 numArgs)
   at System.Windows.Threading.ExceptionWrapper.TryCatchWhen(Object source, Delegate callback, Object args, Int32 numArgs, Delegate catchHandler)
   at System.Windows.Threading.Dispatcher.LegacyInvokeImpl(DispatcherPriority priority, TimeSpan timeout, Delegate method, Object args, Int32 numArgs)
   at MS.Win32.HwndSubclass.SubclassWndProc(IntPtr hwnd, Int32 msg, IntPtr wParam, IntPtr lParam)
   at MS.Win32.UnsafeNativeMethods.DispatchMessage(MSG& msg)
   at System.Windows.Threading.Dispatcher.PushFrameImpl(DispatcherFrame frame)
   at System.Windows.Application.RunDispatcher(Object ignore)
   at System.Windows.Application.RunInternal(Window window)
   at Stride.GameStudio.Program.Main() in C:\BuildAgent\work\b5f46e3c4829a09e\sources\editor\Stride.GameStudio\Program.cs:line 148

@WeeveFerrelaine
Copy link
Author

thx bby ilu

@WeeveFerrelaine
Copy link
Author

Just got what I assume is the same error a second time, while walking away and doing something else- so maybe it's time based, and not user action based? This time the script was compiling, and I had previously ran it a few times during the sesh, but I wasn't even at my PC when it crashed this time.

Log x2:

Application: GameStudio
UserEmail: [email protected]
UserMessage: 
StrideVersion: 4.2.0.2293
GameStudioVersion: 4
ThreadName: Main thread
DefaultGraphicProfile: Level_10_0
OpenedAssets: fc1278d7-a571-4f0b-a61e-8a9970c8adcf:MainScene (Scene)
8cad7d46-4a15-bff1-1be7-852a3f9c0131:Camera (Script Source Code)

LastActions: * +[Update property Components.Sprite.Type]
    * {AssetContentValueChangeOperation: SpriteType = Billboard}
* +[Update property Components.Sprite.Type]
    * {AssetContentValueChangeOperation: SpriteType = Sprite}
* +[Delete selected entities]
    * {AssetContentValueChangeOperation: List`1 --[5] = }
    * {AssetContentValueChangeOperation: AssetPartCollection`2 --[1d96d0aa-921b-43f4-abbd-1b48042753c7] = }
    * {DeletedPartsTrackingOperation`2}
* +[Update property Components.Camera.Lower Camera Pitch]
    * {AssetContentValueChangeOperation: LowerCameraPitch = 5}
* +[Update property Components.Camera.Upper Camera Pitch]
    * {AssetContentValueChangeOperation: UpperCameraPitch = -89.9}

CurrentDirectory: %USERPROFILE%\.nuget\packages\stride.gamestudio\4.2.0.2293\lib\net8.0-windows7.0
CommandArgs: /LauncherWindowHandle 197580 C:\Dev\Projects\Princess of Naught\Princess of Naught.sln
OsVersion: Microsoft Windows 10 Pro 10.0.19045 x64
ProcessorCount: 12
Exception: InvalidOperationException: The calling thread cannot access this object because a different thread owns it.
   at System.Windows.Threading.Dispatcher.<VerifyAccess>g__ThrowVerifyAccess|7_0()
   at Stride.Assets.Presentation.AssetEditors.ScriptEditor.SimpleCodeTextEditor.CaretOnPositionChanged(Object sender, EventArgs eventArgs) in C:\BuildAgent\work\b5f46e3c4829a09e\sources\editor\Stride.Assets.Presentation\AssetEditors\ScriptEditor\SimpleCodeTextEditor.cs:line 187
   at System.Threading.Tasks.Task.<>c.<ThrowAsync>b__128_0(Object state)
   at System.Windows.Threading.ExceptionWrapper.InternalRealCall(Delegate callback, Object args, Int32 numArgs)
   at System.Windows.Threading.ExceptionWrapper.TryCatchWhen(Object source, Delegate callback, Object args, Int32 numArgs, Delegate catchHandler)
   at System.Windows.Threading.DispatcherOperation.InvokeImpl()
   at MS.Internal.CulturePreservingExecutionContext.CallbackWrapper(Object obj)
   at System.Threading.ExecutionContext.RunInternal(ExecutionContext executionContext, ContextCallback callback, Object state)
--- End of stack trace from previous location ---
   at System.Threading.ExecutionContext.RunInternal(ExecutionContext executionContext, ContextCallback callback, Object state)
   at MS.Internal.CulturePreservingExecutionContext.Run(CulturePreservingExecutionContext executionContext, ContextCallback callback, Object state)
   at System.Windows.Threading.DispatcherOperation.Invoke()
   at System.Windows.Threading.Dispatcher.ProcessQueue()
   at System.Windows.Threading.Dispatcher.WndProcHook(IntPtr hwnd, Int32 msg, IntPtr wParam, IntPtr lParam, Boolean& handled)
   at MS.Win32.HwndSubclass.DispatcherCallbackOperation(Object o)
   at System.Windows.Threading.ExceptionWrapper.InternalRealCall(Delegate callback, Object args, Int32 numArgs)
   at System.Windows.Threading.ExceptionWrapper.TryCatchWhen(Object source, Delegate callback, Object args, Int32 numArgs, Delegate catchHandler)
   at System.Windows.Threading.Dispatcher.LegacyInvokeImpl(DispatcherPriority priority, TimeSpan timeout, Delegate method, Object args, Int32 numArgs)
   at MS.Win32.HwndSubclass.SubclassWndProc(IntPtr hwnd, Int32 msg, IntPtr wParam, IntPtr lParam)
   at MS.Win32.UnsafeNativeMethods.DispatchMessage(MSG& msg)
   at System.Windows.Threading.Dispatcher.PushFrameImpl(DispatcherFrame frame)
   at System.Windows.Application.RunDispatcher(Object ignore)
   at System.Windows.Application.RunInternal(Window window)
   at Stride.GameStudio.Program.Main() in C:\BuildAgent\work\b5f46e3c4829a09e\sources\editor\Stride.GameStudio\Program.cs:line 148

GPU0.AdapterCompatibility: NVIDIA
GPU0.AdapterDACType: Integrated RAMDAC
GPU0.AdapterRAM: 4293918720
GPU0.Availability: 3
GPU0.Caption: NVIDIA GeForce GTX 970
GPU0.ConfigManagerErrorCode: 0
GPU0.ConfigManagerUserConfig: False
GPU0.CreationClassName: Win32_VideoController
GPU0.CurrentBitsPerPixel: 32
GPU0.CurrentHorizontalResolution: 1920
GPU0.CurrentNumberOfColors: 4294967296
GPU0.CurrentNumberOfColumns: 0
GPU0.CurrentNumberOfRows: 0
GPU0.CurrentRefreshRate: 60
GPU0.CurrentScanMode: 4
GPU0.CurrentVerticalResolution: 1080
GPU0.Description: NVIDIA GeForce GTX 970
GPU0.DeviceID: VideoController1
GPU0.DitherType: 0
GPU0.DriverDate: 20240601000000.000000-000
GPU0.DriverVersion: 32.0.15.5599
GPU0.InfFilename: oem10.inf
GPU0.InfSection: Section004
GPU0.InstalledDisplayDrivers: C:\Windows\System32\DriverStore\FileRepository\nvpcdig.inf_amd64_715e6d025d9c0e1e\nvldumdx.dll,C:\Windows\System32\DriverStore\FileRepository\nvpcdig.inf_amd64_715e6d025d9c0e1e\nvldumdx.dll,C:\Windows\System32\DriverStore\FileRepository\nvpcdig.inf_amd64_715e6d025d9c0e1e\nvldumdx.dll,C:\Windows\System32\DriverStore\FileRepository\nvpcdig.inf_amd64_715e6d025d9c0e1e\nvldumdx.dll
GPU0.MaxRefreshRate: 75
GPU0.MinRefreshRate: 50
GPU0.Monochrome: False
GPU0.Name: NVIDIA GeForce GTX 970
GPU0.PNPDeviceID: PCI\VEN_10DE&DEV_13C2&SUBSYS_136619DA&REV_A1\4&2283F625&0&0019
GPU0.Status: OK
GPU0.SystemCreationClassName: Win32_ComputerSystem
GPU0.SystemName: LEE
GPU0.VideoArchitecture: 5
GPU0.VideoMemoryType: 2
GPU0.VideoModeDescription: 1920 x 1080 x 4294967296 colors
GPU0.VideoProcessor: NVIDIA GeForce GTX 970
Log: 1: Princess_of_NaughtApp(0,0): []: Fatal: The asset Princess_of_NaughtApp is missing or incorrectly indexed in the package. Please report this issue.
2: Camera(0,0): []: Fatal: The asset Camera is missing or incorrectly indexed in the package. Please report this issue.
3: Princess_of_NaughtApp(0,0): []: Fatal: The asset Princess_of_NaughtApp is missing or incorrectly indexed in the package. Please report this issue.
4: Camera(0,0): []: Fatal: The asset Camera is missing or incorrectly indexed in the package. Please report this issue.
5: Princess_of_NaughtApp(0,0): []: Fatal: The asset Princess_of_NaughtApp is missing or incorrectly indexed in the package. Please report this issue.

@WeeveFerrelaine
Copy link
Author

Huh, I moved my Stride folder, and just noticed that the launcher icon is missing. I wonder if this is related- since the shortcut still worked, I just assumed moving the folder was fine.

Image

@IXLLEGACYIXL
Copy link
Collaborator

no you are just not supposed to move the isntalled files

@WeeveFerrelaine
Copy link
Author

What is the official way to move the install folder? Because right now it works like 99%, and the only issue is these random-feeling crashes.

@IXLLEGACYIXL
Copy link
Collaborator

the first one was a reload issue and the second one was a race condition issue atleast from the error logs

@WeeveFerrelaine
Copy link
Author

WeeveFerrelaine commented Jan 16, 2025

I've got a third one now, not sure if it's unrelated.

Application: GameStudio
UserEmail: [email protected]
UserMessage: I pressed ctrl-S after removing some temporary lines of code. Previously I had renamed some files, but the editor wasn't updating the list of scripts to match the renamed files, so I'd just re-launched it, and then fixed the script (after it still wasn't recognizing the changed names)
StrideVersion: 4.2.0.2293
GameStudioVersion: 4
ThreadName: Main thread
DefaultGraphicProfile: Level_10_0
OpenedAssets: fc1278d7-a571-4f0b-a61e-8a9970c8adcf:MainScene (Scene)
bfa9c842-2ca3-6879-b028-c199218250e1:CharacterControl (Script Source Code)

LastActions: 
CurrentDirectory: %USERPROFILE%\.nuget\packages\stride.gamestudio\4.2.0.2293\lib\net8.0-windows7.0
CommandArgs: /LauncherWindowHandle 263320 C:\Dev\Projects\Princess of Naught\Princess of Naught.sln
OsVersion: Microsoft Windows 10 Pro 10.0.19045 x64
ProcessorCount: 12
Exception: NullReferenceException: Object reference not set to an instance of an object.
   at Stride.Core.Assets.Editor.Services.UserDocumentationService.ClearCachedAssemblyDocumentation(Assembly assembly) in C:\BuildAgent\work\b5f46e3c4829a09e\sources\editor\Stride.Core.Assets.Editor\Services\UserDocumentationService.cs:line 82
   at Stride.GameStudio.ViewModels.DebuggingViewModel.ReloadAssemblies() in C:\BuildAgent\work\b5f46e3c4829a09e\sources\editor\Stride.GameStudio\ViewModels\DebuggingViewModel.cs:line 259
   at Stride.Core.Presentation.Commands.AnonymousTaskCommand.<>c__DisplayClass0_0.<<-ctor>b__0>d.MoveNext() in C:\BuildAgent\work\b5f46e3c4829a09e\sources\presentation\Stride.Core.Presentation\Commands\AnonymousCommand.cs:line 84
--- End of stack trace from previous location ---
   at System.Threading.Tasks.Task.<>c.<ThrowAsync>b__128_0(Object state)
   at System.Windows.Threading.ExceptionWrapper.InternalRealCall(Delegate callback, Object args, Int32 numArgs)
   at System.Windows.Threading.ExceptionWrapper.TryCatchWhen(Object source, Delegate callback, Object args, Int32 numArgs, Delegate catchHandler)
   at System.Windows.Threading.DispatcherOperation.InvokeImpl()
   at MS.Internal.CulturePreservingExecutionContext.CallbackWrapper(Object obj)
   at System.Threading.ExecutionContext.RunInternal(ExecutionContext executionContext, ContextCallback callback, Object state)
--- End of stack trace from previous location ---
   at System.Threading.ExecutionContext.RunInternal(ExecutionContext executionContext, ContextCallback callback, Object state)
   at MS.Internal.CulturePreservingExecutionContext.Run(CulturePreservingExecutionContext executionContext, ContextCallback callback, Object state)
   at System.Windows.Threading.DispatcherOperation.Invoke()
   at System.Windows.Threading.Dispatcher.ProcessQueue()
   at System.Windows.Threading.Dispatcher.WndProcHook(IntPtr hwnd, Int32 msg, IntPtr wParam, IntPtr lParam, Boolean& handled)
   at MS.Win32.HwndWrapper.WndProc(IntPtr hwnd, Int32 msg, IntPtr wParam, IntPtr lParam, Boolean& handled)
   at System.Windows.Threading.ExceptionWrapper.InternalRealCall(Delegate callback, Object args, Int32 numArgs)
   at System.Windows.Threading.ExceptionWrapper.TryCatchWhen(Object source, Delegate callback, Object args, Int32 numArgs, Delegate catchHandler)
   at System.Windows.Threading.Dispatcher.LegacyInvokeImpl(DispatcherPriority priority, TimeSpan timeout, Delegate method, Object args, Int32 numArgs)
   at MS.Win32.HwndSubclass.SubclassWndProc(IntPtr hwnd, Int32 msg, IntPtr wParam, IntPtr lParam)
   at MS.Win32.UnsafeNativeMethods.DispatchMessage(MSG& msg)
   at System.Windows.Threading.Dispatcher.PushFrameImpl(DispatcherFrame frame)
   at System.Windows.Application.RunDispatcher(Object ignore)
   at System.Windows.Application.RunInternal(Window window)
   at Stride.GameStudio.Program.Main() in C:\BuildAgent\work\b5f46e3c4829a09e\sources\editor\Stride.GameStudio\Program.cs:line 148

GPU0.AdapterCompatibility: NVIDIA
GPU0.AdapterDACType: Integrated RAMDAC
GPU0.AdapterRAM: 4293918720
GPU0.Availability: 3
GPU0.Caption: NVIDIA GeForce GTX 970
GPU0.ConfigManagerErrorCode: 0
GPU0.ConfigManagerUserConfig: False
GPU0.CreationClassName: Win32_VideoController
GPU0.CurrentBitsPerPixel: 32
GPU0.CurrentHorizontalResolution: 1920
GPU0.CurrentNumberOfColors: 4294967296
GPU0.CurrentNumberOfColumns: 0
GPU0.CurrentNumberOfRows: 0
GPU0.CurrentRefreshRate: 60
GPU0.CurrentScanMode: 4
GPU0.CurrentVerticalResolution: 1080
GPU0.Description: NVIDIA GeForce GTX 970
GPU0.DeviceID: VideoController1
GPU0.DitherType: 0
GPU0.DriverDate: 20240601000000.000000-000
GPU0.DriverVersion: 32.0.15.5599
GPU0.InfFilename: oem10.inf
GPU0.InfSection: Section004
GPU0.InstalledDisplayDrivers: C:\Windows\System32\DriverStore\FileRepository\nvpcdig.inf_amd64_715e6d025d9c0e1e\nvldumdx.dll,C:\Windows\System32\DriverStore\FileRepository\nvpcdig.inf_amd64_715e6d025d9c0e1e\nvldumdx.dll,C:\Windows\System32\DriverStore\FileRepository\nvpcdig.inf_amd64_715e6d025d9c0e1e\nvldumdx.dll,C:\Windows\System32\DriverStore\FileRepository\nvpcdig.inf_amd64_715e6d025d9c0e1e\nvldumdx.dll
GPU0.MaxRefreshRate: 75
GPU0.MinRefreshRate: 50
GPU0.Monochrome: False
GPU0.Name: NVIDIA GeForce GTX 970
GPU0.PNPDeviceID: PCI\VEN_10DE&DEV_13C2&SUBSYS_136619DA&REV_A1\4&2283F625&0&0019
GPU0.Status: OK
GPU0.SystemCreationClassName: Win32_ComputerSystem
GPU0.SystemName: LEE
GPU0.VideoArchitecture: 5
GPU0.VideoMemoryType: 2
GPU0.VideoModeDescription: 1920 x 1080 x 4294967296 colors
GPU0.VideoProcessor: NVIDIA GeForce GTX 970
Log: 1: CharacterControl(0,0): []: Fatal: The asset CharacterControl is missing or incorrectly indexed in the package. Please report this issue.
2: Princess_of_NaughtApp(0,0): []: Fatal: The asset Princess_of_NaughtApp is missing or incorrectly indexed in the package. Please report this issue.
3: CameraControl(0,0): []: Fatal: The asset CameraControl is missing or incorrectly indexed in the package. Please report this issue.
4: CharacterControl(0,0): []: Fatal: The asset CharacterControl is missing or incorrectly indexed in the package. Please report this issue.
5: Princess_of_NaughtApp(0,0): []: Fatal: The asset Princess_of_NaughtApp is missing or incorrectly indexed in the package. Please report this issue.

@WeeveFerrelaine
Copy link
Author

After the ctrl+S where the script's errors were fixed (and the subsequent crash), re-launching stride, it then shows up properly named in the script list, and Stride is back to acting normal now.

@IXLLEGACYIXL
Copy link
Collaborator

it is related, thanks for reporting

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants