-
-
Notifications
You must be signed in to change notification settings - Fork 23.7k
Fix editor crash when inspecting 2 objects handled by the same plugin #104296
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
Fix editor crash when inspecting 2 objects handled by the same plugin #104296
Conversation
0xcafeb33f
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
1c4f00a to
f936405
Compare
|
When you open a Shader from ShaderMaterial, the material gets folded and you can no longer unfold it. godot.windows.editor.dev.x86_64_mcFfdq1NlV.mp4In 4.5 dev1 trying to open it causes a crash 🙃 |
|
Try with built-in shader. |
Still can't reproduce. |
I tried with a built-in shader on 4.5dev1 both with and without this PR, and I could not reproduce this issue. What type of node are you adding the material to? Is there anything else open in the editor, or present in the project, at the time of the bug occurring? |
|
I can't reproduce it anymore, idk what happened. Maybe I reloaded the scene and the shader wasn't closed properly for some reason (normally all built-in shaders are closed with the scene). The error/crash is probably the same case as #104250, i.e. unfold a shader and restart editor. It's fixed by this PR. |
KoBeWi
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I tested various known errors when editing Resources in the inspector and they seem to be all gone. The ShaderMaterial problem I found might not have been caused by this PR, I didn't spot other problems.
Already activated plugins do not need to be added again to `editor_plugins_over`. `fold_resource()` changes `active_plugins` and is unsafe to call while iterating over `active_plugins`.
f936405 to
411f476
Compare
|
Thanks! |
|
Cherry-picked for 4.4.1. |
Already activated plugins do not need to be added again to
editor_plugins_over.fold_resource()changesactive_pluginsand is unsafe to call while iterating overactive_plugins.Fix #103909, fix #104250, fix #97577.
Close #103976.