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

"Parameter "script_lang" is null" error when pausing a scene that uses no scripts #102185

Open
JekSun97 opened this issue Jan 30, 2025 · 2 comments

Comments

@JekSun97
Copy link
Contributor

JekSun97 commented Jan 30, 2025

Tested versions

4.3 stable, 4.4 beta 2

System information

Godot v4.4.beta2 - Windows 10 (build 19045) - Multi-window, 1 monitor - Vulkan (Forward+) - dedicated Radeon RX 560 Series (Advanced Micro Devices, Inc.; 31.0.21912.14) - Intel(R) Core(TM) i5-4570 CPU @ 3.20GHz (4 threads)

Issue description

I see an error when we pause the game (pause in the upper right corner), which is strange, it only happens in 3D scenes, when launching 2D scenes it does not.

0130.mp4

Steps to reproduce

  1. Create a 3D scene
  2. Run it
  3. Press the pause button in the upper right corner
  4. Error - debug: Parameter "script_lang" is null. <Source code C++>core/debugger/remote_debugger.cpp:420 @ debug()

Minimal reproduction project (MRP)

N/A

@JekSun97 JekSun97 changed the title Error when pausing the game Error when pausing the game in 3D scenes Jan 30, 2025
@akien-mga

This comment has been minimized.

@akien-mga
Copy link
Member

akien-mga commented Jan 30, 2025

Actually I can reproduce the issue, I was testing it wrong.

It happens when pausing with the pause button in the run bar / top right corner, and not with the pause button in the embedded game viewport.

It happens with both 2D and 3D scenes (or plain Node, that's not the factor), whenever no node in the scene has a script. Hence the script related error.

It's reproducible in 4.4-beta2, 4.3-stable and 4.2-stable (didn't test earlier), so it's not a recently introduced bug.

The problem is in RemoteDebugger::debug which assumed that any paused scene must have an active script language, so it can trigger script debugging logic. This needs to be refactored a bit to gracefully handle pausing when no script exists. I'm not sure whether it means no debugger should be started at all, or if we can still have debuggers/profilers active without the script part.

@akien-mga akien-mga changed the title Error when pausing the game in 3D scenes "Parameter "script_lang" is null" error when pausing a scene that uses no scripts Jan 30, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

3 participants