fix(launcher): show log init errors in GUI mode (#1734)#1741
Open
darrenzeng2025 wants to merge 1 commit intosipeed:mainfrom
Open
fix(launcher): show log init errors in GUI mode (#1734)#1741darrenzeng2025 wants to merge 1 commit intosipeed:mainfrom
darrenzeng2025 wants to merge 1 commit intosipeed:mainfrom
Conversation
When the launcher fails to initialize the log file in GUI mode (non-console), the error message was being written to stderr which is not visible to users. This fix re-enables console logging before logging the error, ensuring that users can see the error message even in GUI mode. Fixes sipeed#1734
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Description
This PR fixes issue #1734 where log file initialization errors are not visible when running the launcher in GUI mode.
Problem
When the launcher with GUI cannot open the log file (e.g., due to permission issues), it would exit with error code 1 but show no output to the user. This is because:
Solution
Before logging the error and exiting, re-enable console logging to INFO level so the error message is visible to users.
Changes
Type of Change
AI Code Generation
Related Issue
Fixes #1734
Test Environment
Checklist