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
Silent printing not working in combination with deviceName (in v5.0.7 +) #19474
Comments
yeah, struggling with this issue from v3.1.11 |
This issue is not fixed yet. V6.0.0 |
@sarathjasrin yes, i'm aware - if it had been fixed, this issue would be closed. I plan to work it on it very soon. |
Hey folks, got a PR up targeting master that should ensure it's fixed in v7. I won't be able to port it in its current state back to v6 and v5 owing to some intermediary changes Chromium made but i'll do my best and should hopefully be able to get it fixed in those lines too. |
Thanks @codebytere, that's very good news. Unfortunately the release of v7 is 3 months away. Lets keep our fingers crossed that we can get some fixes in any of the stable releases sooner because v3 is already getting old in the tooth. |
Has this been backported to any of the stable releases yet, like v5 or v6? |
Any news on fixes for cases 4 and 5 being shipped before v7? |
It's trange that this issue has been closed but the fix is not avalable in any stable release. |
@gozzoo It will available from V7. she mentioned above.
|
@sarathjasrin well, but v7 has not been released. My point is that this issue has been closed, but we can not consider it fixed yet, because the fix is not available in any stable release. It's good to know that a fix exists and it will be included in the future version, but v7 is not production ready yet. And when v7 eventually gets releaed it will come with its own set of issues (as the history of electron has shown), and it will take some time before it gets wide adoption. I don't expect to be able to use v7 before the start of next year, possible much latter. Some people are still struggling to upgrade to v6, which was announced as stable few months ago. (see vscode - and they didn't even try v5) That's why I think that it's very important for this fix to be backported to some of the stable releases, at least v6. Most projects that use printing (as mentioned in some comments above) are still stuck with v3. Not many (if any) of the big adopters of electron (slack, vscode,, skype, WhatsApp, atom, ...) use printing in their products and there is no strong push to make printing work properly. Obviously It doesn't get as much love as some other more demanded features. As a result printing has been a chronic problem of electron for quite some time. I hope you see now why I'm a little bit sceptical about such promise: don't worry, it's fixed, you'll get it in the next version, case closed. |
@gozzoo I can understand. I'm also struggled with this issue ended up creating console application for printing in C#. |
Preflight Checklist
Issue Details
Expected Behaviors
According to the pull request #19038 which was merged in v.5.0.7, silent printing should work.
webContents.print()
webContents.print({ silent: true })
webContents.print({ silent: true, printBackground: true })
webContents.print({ silent: true, deviceName: 'Canon_MF633C_635C' })
webContents.print({ silent: true, deviceName: printBackground: true, deviceName: 'Canon_MF633C_635C' })
Original documentation of WebContents.print() can be found here.
Actual Behaviors
Unfortunately when providing a deviceName, nothing is send to the printer and the callback will never be called (see image of terminal logs below).
To Reproduce
yarn install
andyarn start
Additional Information
For other developers that need to print silently to a predefined printer, the last known version I found to work is v3.1.11.
The text was updated successfully, but these errors were encountered: