Getting Logging Error: Failed to initialize logging system. when running app

Hello,

For some reason since yesterday whenever I run an build and run an app on my Mac I get this issue:

Logging Error: Failed to initialize logging system. Log messages may be missing. If this issue persists, try setting IDEPreferLogStreaming=YES in the active scheme actions environment variables.

I tried to create an iOS app and this is the issue I get in the console when running it on simulator.
This issue also appears on old projects I have.

Setting IDEPreferLogStreaming=YES in environment variables does fix the issue and the error no longer appears but why is it appearing in the first place and how can I get rid of it?

Here is a screenshot:

Thanks in advance for your help.

That error message indicates that the app has not performed initialization quickly enough after launching the debug session, and the Xcode Console may not be receiving log messages from the app.

It's possible for the debug session to take longer on first launch, which may cause the error to show up even though initialization completes soon afterwards. You can safely ignore the error if you see all your expected log messages from Logger (Swift) or os_log (Objective-C) APIs.

Starting with Xcode 16 Beta 1, this error should no longer be visible.

Getting Logging Error: Failed to initialize logging system. when running app
 
 
Q