firebelley / godot-export

Automatically exports your Godot games.
MIT License
460 stars 53 forks source link

Build hanging on import game #127

Open Polemus opened 7 months ago

Polemus commented 7 months ago

Hi There,

Would there be any reason why builds would suddenly hang on import game?

🎲 Import project /home/runner/.local/share/godot/godot_executable/Godot_v4.1.3-stable_mono_linux_x86_64/Godot_v4.1.3-stable_mono_linux.x86_64 /home/runner/work/Blue/Blue/src/project.godot --headless -e --quit Godot Engine v4.1.3.stable.mono.official.f06b6836a - https://godotengine.org/

WARNING: Custom cursor shape not supported by this display server. at: cursor_set_custom_image (servers/display_server.cpp:480)

This used to run until a few days ago, now it just gets stuck at the warning using up precious action minutes :)

Export runs fine locally, and this warning has always been there.

JulienLavocat commented 7 months ago

Hi, I have the issue on my builds, it works locally but not in a GA pipeline. I tried various things like downgrading to Godot 4.1 (which was working before) but it still hangs forever, same when running the pipeline locally using act

One thing that I tried was to basically recreate what this action does and it still had the issue so it might be coming from Github Runners but I'm not sure how to prove it.

Polemus commented 6 months ago

It seems like it only happens with mono games.

outfrost commented 4 months ago

My build just hung on importing project. I'm not using Mono, but I do have a GDExtension in the project.

https://github.com/outfrost/godot-wild-jam-66/actions/runs/7879859504/job/21500903651

There were errors such as

  SCRIPT ERROR: Parse Error: Identifier "FmodServer" not declared in the current scope.
            at: GDScript::reload (res://addons/fmod/FmodManager.gd:7)

suggesting that the fmod addon wasn't actually loaded.

After listing off some more import warnings and errors, the job just sat idle for several minutes.

outfrost commented 4 months ago

Did a bit of digging.

This appears to be a problem with Godot itself, as running the editor binary on my project with --headless and either --export-release or -e --quit causes it to go into idle.

godotengine/godot#57016 seems related. Essentially, what is likely happening is the editor "displays" a dialogue box with some kind of error/warning/question, and expects an answer, but obviously there is no way to answer in headless mode.

brogan89 commented 1 month ago

I've run into this issue as well and temporarily made a shell script to build my game locally.

Adding a line that runs Godot and times out then run Godot again to build my templates works for me

timeout 10s "$GODOT_PATH" --headless --import --path "./src"

"$GODOT_PATH" --headless --path "./src" --export-release "Windows" || exit
"$GODOT_PATH" --headless --path "./src" --export-release "Mac" || exit
"$GODOT_PATH" --headless --path "./src" --export-release "Linux" || exit

My guess is you'd need to add something similar to the doExport() function.