Skip to content
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

chore: improve renderer crash logging #25592

Merged
merged 1 commit into from Sep 24, 2020
Merged

Conversation

miniak
Copy link
Contributor

@miniak miniak commented Sep 23, 2020

Description of Change

Follow up to #25317

Checklist

  • PR description included and stakeholders cc'd
  • npm test passes
  • PR title follows semantic commit guidelines

Release Notes

Notes: no-notes

@electron-cation electron-cation bot added the new-pr 🌱 PR opened in the last 24 hours label Sep 23, 2020
@miniak miniak mentioned this pull request Sep 23, 2020
4 tasks
@@ -462,8 +462,7 @@ const addReturnValueToEvent = (event: any) => {
};

const loggingEnabled = () => {
return Object.prototype.hasOwnProperty.call(process.env, 'ELECTRON_ENABLE_LOGGING') ||
process.argv.some(arg => arg.toLowerCase().startsWith('--enable-logging'));
return process.env.ELECTRON_ENABLE_LOGGING || app.commandLine.hasSwitch('enable-logging');
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

teeeeechnically the logic for this in base::Environment is different. Ideally we'd just query this info directly from the C++ which actually controls logging, rather than trying to reimplement this.

Things that enable logging in the C++ without tripping this test, for example:

ELECTRON_ENABLE_LOGGING=0
electron_enable_logging=1

# only on non-Windows platforms:
ELECTRON_ENABLE_LOGGING=

I don't think it's very important to match exactly, but JFYI.

@electron-cation electron-cation bot removed the new-pr 🌱 PR opened in the last 24 hours label Sep 24, 2020
@codebytere codebytere merged commit 1f856c2 into master Sep 24, 2020
@release-clerk
Copy link

release-clerk bot commented Sep 24, 2020

No Release Notes

@trop
Copy link
Contributor

trop bot commented Sep 24, 2020

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

@trop trop bot removed the target/11-x-y label Sep 24, 2020
@trop
Copy link
Contributor

trop bot commented Sep 24, 2020

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

@trop
Copy link
Contributor

trop bot commented Sep 24, 2020

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

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

4 participants