Skip to content
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 4 additions & 1 deletion web/backend/main.go
Original file line number Diff line number Diff line change
Expand Up @@ -81,7 +81,10 @@ func main() {

logPath := filepath.Join(picoHome, "logs", "web.log")
if err := logger.EnableFileLogging(logPath); err != nil {
fmt.Fprintf(os.Stderr, "Failed to initialize logger: %v\n", err)
// Re-enable console logging so the error is visible in GUI mode
logger.SetConsoleLevel(logger.INFO)
logger.Errorf("Failed to initialize log file at %s: %v", logPath, err)
logger.Error("Please check that the logs directory is writable")
os.Exit(1)
}
defer logger.DisableFileLogging()
Expand Down
Loading