Bug 195769 - Active EventSource prevents window.print() from working in Safari 12
Summary: Active EventSource prevents window.print() from working in Safari 12
Status: NEW
Alias: None
Product: WebKit
Classification: Unclassified
Component: Printing (show other bugs)
Version: Safari 12
Hardware: Mac macOS 10.13
: P2 Normal
Assignee: Nobody
URL: https://jsfiddle.net/43ufcxkw/
Keywords: InRadar
Depends on:
Blocks:
 
Reported: 2019-03-14 15:06 PDT by Daniel LeCheminant
Modified: 2019-03-16 13:24 PDT (History)
2 users (show)

See Also:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Daniel LeCheminant 2019-03-14 15:06:46 PDT
Repro:

1. Visit a site with an active event source, e.g. https://simpl.info/eventsource/
2. Run window.print() from the console

Expected:

Print dialog opens, or some indication that a print is being attempted

Actual:

Nothing happens

Related:

I expect this is also the cause of https://github.com/launchdarkly/js-client/issues/121
Comment 1 Daniel LeCheminant 2019-03-14 15:12:23 PDT
If it's helpful, I have a simple repro at https://jsfiddle.net/43ufcxkw/

The print on that page works in Chrome 72, but does not work in Safari 12.
Comment 2 Daniel LeCheminant 2019-03-15 09:53:59 PDT
As a workaround, document.execCommand('print') does appear to work in Safari.
Comment 3 Radar WebKit Bug Importer 2019-03-16 13:24:51 PDT
<rdar://problem/48955771>