Skip to content

fix: fail non-fatally when InitLogging fails - #35138

Merged
jkleinsc merged 1 commit into
mainfrom
no-crash-on-init-logging-fail
Aug 2, 2022
Merged

fix: fail non-fatally when InitLogging fails#35138
jkleinsc merged 1 commit into
mainfrom
no-crash-on-init-logging-fail

Conversation

@nornagon

Copy link
Copy Markdown
Contributor

Some apps use logging in production to collect data in the wild. However,
there's no way for such apps to recover from a situation in which logging fails
(e.g. if the log file location is not accessible).

Instead of crashing, log (?) an error and continue.

Notes: Do not exit when logging initialization fails.

@nornagon nornagon added semver/patch backwards-compatible bug fixes target/20-x-y labels Jul 29, 2022
@electron-cation electron-cation Bot added the new-pr 🌱 PR opened recently label Jul 29, 2022
@deepak1556

Copy link
Copy Markdown
Member

When initializing logging fails, how does PLOG(ERROR) surface to the users ? Does the runtime log to stderr in this case ?

@electron-cation electron-cation Bot removed the new-pr 🌱 PR opened recently label Jul 30, 2022
@jkleinsc

jkleinsc commented Aug 2, 2022

Copy link
Copy Markdown
Member

Merging as CI failure unrelated to PR change.

@jkleinsc
jkleinsc merged commit 3d4d1b3 into main Aug 2, 2022
@jkleinsc
jkleinsc deleted the no-crash-on-init-logging-fail branch August 2, 2022 19:45
@release-clerk

release-clerk Bot commented Aug 2, 2022

Copy link
Copy Markdown

Release Notes Persisted

Do not exit when logging initialization fails.

@trop

trop Bot commented Aug 2, 2022

Copy link
Copy Markdown
Contributor

I have automatically backported this PR to "20-x-y", please check out #35190

schetle pushed a commit to schetle/electron that referenced this pull request Nov 3, 2022
khalwa pushed a commit to solarwindscloud/electron that referenced this pull request Feb 22, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

semver/patch backwards-compatible bug fixes

Projects

None yet

Development

Successfully merging this pull request may close these issues.

5 participants