-
-
Notifications
You must be signed in to change notification settings - Fork 449
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[UX] Enable/disable logs game-by-game instead of globally #4214
base: main
Are you sure you want to change the base?
Conversation
@@ -262,7 +261,7 @@ export async function launchGame( | |||
logFile: lastPlayLogFileLocation(appName), | |||
logMessagePrefix: LogPrefix.Backend, | |||
onOutput: (output) => { | |||
if (!logsDisabled) appendGamePlayLog(gameInfo, output) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
probably should add that
if (!gameSettings.verboseLogs) {
appendGamePlayLog(
gameInfo,
'IMPORTANT: Logs are disabled. Enable verbose logs before reporting an issue.'
)
}
here as well ?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
hmmm looks like we have some issues with how we log things with sideloaded games, for native games the logs are just broken (we log the wrong thing in the wrong file and no system info / config)
I'm trying to fix that, but feel that should be its own PR to limit the scope of this one
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
lgtm other than that one small thing
child.stderr.on('data', (data) => { | ||
appendGamePlayLog(gameInfo, data.toString()) | ||
child.on('error', (err: Error) => { | ||
if (gameSettings.verboseLogs) { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Perhaps errors should ignore this option? They're not exactly frequent after all
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
My only concern with this is that users may see an error message and miss the IMPORTANT: Logs are disabled. Enable verbose logs before reporting an issue
line and send it anyway without turning on logs (I know it's going to happen anyway, but I think not having anything apart from that line would reduce it the chances)
5494279
to
6a5e903
Compare
Currently, we can only enable/disable logs globally to log game output.
This has some issues:
This PR changes that so we can enable
verbose logs
in a game-by-game basis. Some benefits:This also enables me to do another change I want to do related to logs and UX, but I'll keep that in another PR to keep this one smaller.
Use the following Checklist if you have changed something on the Backend or Frontend: