You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
If the lambda is replaced by a regular callable (eg. do_boop.bind(...)), then the editor will provide helpful error messages and debugging information:
I would expect something similar when a lambda is being used.
Steps to reproduce
This is the script from the attached MRP. The key points appear to be:
The signal is defined in a persistent location (ie. doesn't itself get free'd)
A lambda is used in the connect call
The crash is triggered on the emit() call
extendsNode2Dsignalboopfunc_ready():
varlevel : Node2D=$Levelprint("Connecting")
# Will show runtime errors in editor#boop.connect(do_boop.bind(level))# Will crash with no editor feedbackboop.connect(func(): do_boop(level))
print("Freeing")
level.queue_free()
awaitget_tree().create_timer(0.1).timeoutprint("Emitting")
boop.emit()
print("Done")
funcdo_boop(level):
level.position=Vector2.ZERO
(Strangely, if running in the editor, the Emitting text does not appear in the output tab, though it does appear in STDERR)
Minimal reproduction project
Self-contained scene which reliably reproduces the crash:
Godot version
v4.1.2.rc.custom_build [6884be6]
System information
Godot v4.1.2.rc (6884be6) - Debian GNU/Linux trixie/sid trixie - Vulkan (Mobile) - dedicated NVIDIA GeForce GTX 1060 (nvidia) - Intel(R) Core(TM) i5-8400 CPU @ 2.80GHz (6 Threads)
Issue description
When:
The game will crash. If running in the editor, no feedback is produced in the output or debugger.
I initially saw this on
v4.1.stable.official [970459615]
, so compiled the engine from the current4.1
tag to get a backtrace with debug symbols:Expectation
If the lambda is replaced by a regular callable (eg.
do_boop.bind(...)
), then the editor will provide helpful error messages and debugging information:I would expect something similar when a lambda is being used.
Steps to reproduce
This is the script from the attached MRP. The key points appear to be:
signal
is defined in a persistent location (ie. doesn't itself get free'd)connect
callemit()
call(Strangely, if running in the editor, the
Emitting
text does not appear in the output tab, though it does appear in STDERR)Minimal reproduction project
Self-contained scene which reliably reproduces the crash:
lambda_crash.zip
The text was updated successfully, but these errors were encountered: