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

Parser Error: Native class "EditorSpinSlider" cannot be constructed as it is abstract. #93854

Closed
MikeSchulze opened this issue Jul 2, 2024 · 3 comments
Labels

Comments

@MikeSchulze
Copy link

MikeSchulze commented Jul 2, 2024

Tested versions

v4.3.beta2.mono.official [b75f048]

System information

Windows 11

Issue description

I'm working on a new plugin to build by procedural nodes via visual scripting and build my own custom graph nodes.
As example:
image

To have the same Look&Feel I rebuild the property editors used by the Godot editor inspector. (The original property editors are not public, but why?)

I used the Godot provided class EditorSpinSlider
And it works fine, so far so good.

But i have a unit test coverage and it fails when loading my ui components by error

Parser Error: Native class "EditorSpinSlider" cannot be constructed as it is abstract.

From the documentation, it is not abstract.
This blocks me actually to develop and test the scene and often needs a restart of the Godot editor.
It also blocks me to write unit tests because the scene is loaded via a test API and not instantiated by a plugin.

Steps to reproduce

Use the attached example plugin.
When the project opened, it shows the example in the bottom.
image

The scene is loaded and the custom panel using the EditorSpinSlider works fine.
But when you try to run the panel scene itself, it fails with the error.
Parser Error: Native class "EditorSpinSlider" cannot be constructed as it is abstract.
image

This makes it impossible to test the scene manually or by a testing framework.

Minimal reproduction project (MRP)

EditorSpinSlider.zip

@alvinhochun
Copy link
Contributor

Correct me if I'm wrong, but I think it's because EditorSpinSlider, being an editor control, is only available when running inside the editor, so they cannot be constructed when running the scene as a game.

Probably the same issue as #73525.

@MikeSchulze
Copy link
Author

Correct me if I'm wrong, but I think it's because EditorSpinSlider, being an editor control, is only available when running inside the editor, so they cannot be constructed when running the scene as a game.

Yes is described as editor control, but creating a scene and running it for testing makes it impossible if it is recognized as abstract.

@AThousandShips
Copy link
Member

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

No branches or pull requests

3 participants