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: add logging for print_backend failures #29884
Conversation
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.
We propagate user facing generic error on failure cases of obtaining a valid printer
electron/shell/browser/api/electron_api_web_contents.cc
Lines 2369 to 2373 in 2131992
if (printer_name.empty() || !IsDeviceNameValid(printer_name)) { | |
if (print_callback) | |
std::move(print_callback).Run(false, "no valid printers available"); | |
return; | |
} |
If we want to distinguish the failures further, shouldn't they be added to final user facing error message ?
2ffdd11
to
ca1068d
Compare
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 in general
ca1068d
to
ed6c90f
Compare
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.
Looks like linux arm DCHECK crashes are related.
@deepak1556 yeah i'm seeing:
is this something you think we should try to fix ourselves or just not run this specific test there given it was already not succeeding? Ah wait i missed this was a crash and not just a failure - hmmmm i'll look into it though it's slightly baffling given that this isn't really a behavioral change in terms of Chromium functions being called. |
ed6c90f
to
24e876a
Compare
Looks like the DCHECK fails once the print backend mojom has a failure (not sure why the |
00634f8
to
4f66136
Compare
4f66136
to
298d420
Compare
No Release Notes |
I have automatically backported this PR to "15-x-y", please check out #31286 |
I have automatically backported this PR to "14-x-y", please check out #31287 |
I have automatically backported this PR to "16-x-y", please check out #31288 |
Description of Change
Refs:
Chromium recently added the ability to distinguish between no printer(s) and a query failure. I don't think a failure to enumerate printers should result in a user-facing error, but we should at least log this nuance instead of dropping it on the ground.
Checklist
npm test
passesRelease Notes
Notes: none