How to start Godot editor from command line and receive error output?

:information_source: Attention Topic was automatically imported from the old Question2Answer platform.
:bust_in_silhouette: Asked By kyuth

I’m on macOS, if I start the editor from the command line it opens the project list normally and prints output but when I select a project and start the editor the Godot program started from the command line returns and no more output is printed.

Editor starts normally but I can’t get error output from the editor for example when the editor crashes (which has happened more in latest betas).

I do this on Linux so I can explain that but I am not sure about Windows as I havent used that in 2 decades. Are you on Linux?

Gluon | 2023-02-06 13:34

I’m on macOS but it is similar to Linux so if you can describe how it works on Linux I may be able to figure it out on macOS too.

kyuth | 2023-02-06 13:49

:bust_in_silhouette: Reply From: Gluon

Okay so per your message I can confirm that on linux I run the following line on a command line

./godot --verbose

the section ./ represents Linux being told to run an application, godot is the application and the --verbose is an argument passed to state run it will all errors and notifications posted in the command line.

Hope that helps

Thanks, this is difficult to explain but the actual problem is that I cannot see the output what Godot editor prints. So on macOS the equal command is

/Applications/ --verbose

And that opens the project list and prints output and works fine. But when a project is selected and loaded, then the command line returns the control to the user and doesn’t print output anymore.

So I can see only the debug messages that are printed when the project list is open. When I open a project the there is no more debug messages and I don’t know how to see them.

This might be something macOS-specific. Why I’m trying to solve this is that the Godot 4 editor crashes a lot when I run a project but I cannot create a bug report because I don’t have any output, no error message or anything that developers could use to debug and fix it.

kyuth | 2023-02-06 14:40

Ahh well that may be a mac thing then, on my Linux version I continue to get the messages after a project is open. I know there are a lot of things that apple hive off in the background so perhaps its not possible for godot to print those messages on a mac? Sorry i couldnt help further.

Gluon | 2023-02-06 14:42

This is old, but since it’s the first thing I found searching for this issue I’d like to provide a solution for future searchers.

It’s actually simple: Running /Applications/ really only runs the scene selector. When you select a scene in that, a new instance of Godot is started.

The command to open the Editor itself is godot -e.

So to get error logs for the actual editor:

  1. cd to your project directory
  2. run /Applications/ -e --verbose

That’s it. :slight_smile:

Source: Command line tutorial — Godot Engine (stable) documentation in English

1 Like

Thanks for adding a solution! Just a small correction, technically it’s the “Project Manager”, not “Scene Selector”.