A mail client as a webapp on one side, epiphany on the other. Nov 07 10:29:09 classic epiphany[2769]: Error writing selection data: Error writing to file descriptor: Broken pipe Nov 07 10:29:12 classic epiphany[8460]: gdkselection-wayland.c:266: error reading selection buffer: Operation was cancelled Nov 07 10:29:40 classic epiphany[2769]: Error writing selection data: Error writing to file descriptor: Broken pipe Nov 07 10:29:58 classic epiphany[8460]: gdkselection-wayland.c:266: error reading selection buffer: Operation was cancelled When trying to paste a URL from epiphany's URL bar to the mail client, the mail client's UI hangs. It's also causing other applications to fail to paste: Nov 07 10:34:09 classic gnome-terminal-[2939]: gdkselection-wayland.c:266: error reading selection buffer: Operation was cancelled The first bug is that the selection data cannot be written to, the 2nd one would be that the act of requesting the paste data looks like it's synchronous and hangs the main loop. webkitgtk4-2.18.2-1.fc27.x86_64 epiphany-3.26.1-1.fc27.x86_64
Might be relevant: https://bugs.webkit.org/show_bug.cgi?id=164983 https://bugzilla.gnome.org/show_bug.cgi?id=769835
(In reply to Bastien Nocera from comment #0) > A mail client as a webapp on one side, epiphany on the other. > > Nov 07 10:29:09 classic epiphany[2769]: Error writing selection data: Error > writing to file descriptor: Broken pipe > Nov 07 10:29:12 classic epiphany[8460]: gdkselection-wayland.c:266: error > reading selection buffer: Operation was cancelled > Nov 07 10:29:40 classic epiphany[2769]: Error writing selection data: Error > writing to file descriptor: Broken pipe > Nov 07 10:29:58 classic epiphany[8460]: gdkselection-wayland.c:266: error > reading selection buffer: Operation was cancelled Hmm, this is funky, these paths in gdk shouldn't be hit during intra-app c&p. I think this is a problem in gtk+/mutter. > > When trying to paste a URL from epiphany's URL bar to the mail client, the > mail client's UI hangs. Checking Source/WebKit/WebProcess/WebCoreSupport/WebPlatformStrategies.cpp, it seems the readFromClipboard request is synchronous. This ideally would be made asynchronous, but gets less urgent if the first is fixed. I'll happily review patches though :).
(In reply to Carlos Garnacho from comment #2) > Hmm, this is funky, these paths in gdk shouldn't be hit during intra-app > c&p. I think this is a problem in gtk+/mutter. It's really inter-app, because the Ephy web app and browser instance are actually separate processes. > > When trying to paste a URL from epiphany's URL bar to the mail client, the > > mail client's UI hangs. > > Checking Source/WebKit/WebProcess/WebCoreSupport/WebPlatformStrategies.cpp, > it seems the readFromClipboard request is synchronous. This ideally would be > made asynchronous, but gets less urgent if the first is fixed. I'll happily > review patches though :). Fixing this would require modifying a bunch of macOS, iOS, and Windows code, and convincing Ryosuke to allow it. So it's not for the faint of heart.
FWIW I cannot reproduce... is the mail client GMail?
(In reply to Michael Catanzaro from comment #4) > FWIW I cannot reproduce... is the mail client GMail? It's Zimbra, but I don't think that the problem is with the mail client. It started happening this morning in my main browser (I can't paste to anything from epiphany). I can paste to it just fine though. This is the error message that epiphany throws every time I try to copy something: Nov 07 03:33:22 classic epiphany[2769]: Error writing selection data: Error writing to file descriptor: Broken pipe
(In reply to Michael Catanzaro from comment #3) > (In reply to Carlos Garnacho from comment #2) > > Hmm, this is funky, these paths in gdk shouldn't be hit during intra-app > > c&p. I think this is a problem in gtk+/mutter. > > It's really inter-app, because the Ephy web app and browser instance are > actually separate processes. Yeah, but AFAIR wayland is not involved at all, it's all just IPC between ui and web processes. To ephy it's just c&p between 2 widgets, and gtk+ has shortcuts that shouldn't hit windowing requests.
(In reply to Carlos Garnacho from comment #6) > Yeah, but AFAIR wayland is not involved at all, it's all just IPC between ui > and web processes. To ephy it's just c&p between 2 widgets, and gtk+ has > shortcuts that shouldn't hit windowing requests. No, in Bastien's example it's actually two separate Epiphany processes. The flow is: Web process #1 -> UI process #1 -> mutter -> UI process #2 -> web process #2 (Of course, that doesn't mean there's not a WebKit bug.)
(In reply to Michael Catanzaro from comment #7) > (In reply to Carlos Garnacho from comment #6) > > Yeah, but AFAIR wayland is not involved at all, it's all just IPC between ui > > and web processes. To ephy it's just c&p between 2 widgets, and gtk+ has > > shortcuts that shouldn't hit windowing requests. > > No, in Bastien's example it's actually two separate Epiphany processes. The > flow is: > > Web process #1 -> UI process #1 -> mutter -> UI process #2 -> web process #2 > > (Of course, that doesn't mean there's not a WebKit bug.) It also happens when copy/pasting from epiphany to a standard GTK+ app. So the shorter: Web process #1 -> UI process #1 -> mutter -> UI process #2
Any chance you are able to reproduce the problem on a website that doesn't require a login?
(In reply to Michael Catanzaro from comment #9) > Any chance you are able to reproduce the problem on a website that doesn't > require a login? At the time, I reproduced the problem when copy/pasting from the epiphany URL bar (any site at all), to a terminal or polari. I rebooted since then, and the problem doesn't happen any more, but my (wild) guess is that ephy takes too long to reply to the selection request, and the request times out. I think that running some integration tests with no new fds available might be a good idea.