-
-
Notifications
You must be signed in to change notification settings - Fork 21.3k
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
Some C# Signals Don't Automatically Disconnect After QueueFree #89116
Comments
As a note that may be helpful, using the older way of connecting signals |
This is a known issue.. So much so, it's in the documentation. |
I was unaware it was a known issue, so thank you for pointing that out! I will note that the documentation you referred to is not for the stable version of the engine so the reach of that info may be a bit harder to come by until 4.3 comes around. Should I close the issue since it's a duplicate? |
It just hasn't been cherry picked yet, it will be as it's marked for cherry picking, so this can be closed :) |
Sounds good! |
Tested versions
Reproducible in v4.2.1.stable.mono.official [b09f793]
System information
Windows 11
Issue description
Certain kinds of signals connected with C# does not automatically disconnect after the Node is freed. Intended functionality should be that all connected signals should be automatically disconnected as part of the cleanup process. An example of a signal that doesn't disconnect is you have Node A that defines a user created signal. Node B connects that signals on
_Ready()
. When Node B is removed withQueueFree()
and Node A emits the signal, Node B, which has been deleted from memory, still executes the connected signal. A workaround is on_ExitTree()
you can manually disconnect the signal but this should not be necessary.Steps to reproduce
IsInstanceValid()
Minimal reproduction project (MRP)
c_sharp_signal_bug.zip
The text was updated successfully, but these errors were encountered: