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

[Resolved, User Error] [Godot 3.4.2, X11 Linux] Plugin cannot be properly loaded after install #80

Closed
TrainDoctor opened this issue Dec 22, 2021 · 1 comment

Comments

@TrainDoctor
Copy link

TrainDoctor commented Dec 22, 2021

### Steps:
1. Install godot-console from AssetLibrary or import from a zip file.
2. Open the Project settings and select "Plugins".
3. Enable quentincaffeino-console
4. Error seen below will print to console.

Error Message:

 Resource: 'res://addons/quentincaffeino/console/src/Console.tscn' is already being loaded. Cyclic reference?
 res://addons/quentincaffeino/console/src/ConsoleLine.gd:34 - Parse Error: The identifier "Console" isn't declared in the current scope.
 modules/gdscript/gdscript.cpp:566 - Method failed. Returning: ERR_PARSE_ERROR

### Project:
I've included the project in question for easy of re-creation. Please note that I have enabled dialogic and scatter in my plugin settings.
Demo.zip

System:

Model: Acer Aspire E5-576 V1.49
Distro: Arch Linux x86_64
Kernel: Linux 5.15.10-arch1-1
Desktop Environment: KDE
CPU: 4 x Intel(R) Core(TM) i3-8130U CPU @ 2.20GHz
GPU: Intel Corporation UHD Graphics 620 (rev 07)
RAM: 5811 MiB
Godot Version: 3.4.2.stable.official.45eaa2daf

Happy to provide any additional information as needed. Would love to use this in my project(s)

Well, that's egg on my face. I attached the Node to a scene (it's been a while since I've used Godot proper) and it works perfectly fine now... 🤦🏻

Read the below message, I had the right idea but I hadn't realized that the console was loaded automatically as a singleton. Whoops.

@TrainDoctor TrainDoctor changed the title [Godot 3.4.2, X11 Linux] Plugin cannot be properly loaded after install [Resolved, User Error] [Godot 3.4.2, X11 Linux] Plugin cannot be properly loaded after install Dec 22, 2021
@quentincaffeino
Copy link
Owner

Hey. Thanks for awesomely constructed issue)

Not sure I understood the part about attaching node to a scene since with console it should happen automatically. When you enable the console a bunch of stuff changes in your project: (1) autoload list, a console node is added there; (2) default keybindings are registered in input map.

This problem is more broad an it is also discussed here: #51

What I think is happening when you open godot editor it precompiles and loads things that are marked as autoload singletons to speedup project startup, that's where your issue might come from where it tries to load singleton multiple times. Another side effect which you might encounter which is discussed in issue I linked is instances godot has loaded in editor never get released causing a leak. So you might see leaks from console but I haven't encountered any real leak from it and those you see are only because you use the editor. If you run your project directly (godot .) everything is fine.

To be honest I'm not sure if this problem is because of the way this project is written or it is a real issue within godot. I haven't got much time to test this issue with a smaller repro addon.

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

No branches or pull requests

2 participants