Copy/paste within Firefox fails to paste
Categories
(Core :: Widget: Gtk, defect, P2)
Tracking
()
People
(Reporter: campbell, Unassigned)
References
(Blocks 1 open bug)
Details
Attachments
(1 file)
509.79 KB,
text/x-log
|
Details |
User Agent: Mozilla/5.0 (X11; Linux x86_64; rv:86.0) Gecko/20100101 Firefox/86.0
Steps to reproduce:
Start Firefox with:
MOZ_ENABLE_WAYLAND=1
GTK_BACKEND=wayland
QT_QPA_PLATFORM=wayland
firefox-nightly
Copy from a page or URL bar, and try to paste anywhere inside Firefox. It hangs for a moment, then returns control to the user without pasting.
-
Copy/paste within other applications works fine.
-
Pasting from FF into other applications works fine.
-
Pasting from other applications into FF works fine.
-
Dragging text selections within a text box in FF works fine.
-
my system is manjaro-latest on swaywm (wayland). GTK version 1:3.24.24-2 .
Actual results:
-
If i watch the clipboard in a separate terminal with
wl-paste -w wl-paste
, I can see that Copy works fine (according to wayland clipboard). But FF fails on paste. -
Firefox reports an error to stdout on the faild paste:
(firefox:220341): Gdk-WARNING **: 11:36:10.179: Error writing selection data: Error writing to file descriptor: Broken pipe
-
Attached a log generated with
WAYLAND_DEBUG=1 firefox-nightly > clipboard.log
in case it helps. I loaded a page, copied text, tried (and failed) to paste it into the location bar, then closed FF. The interesting part starts at 1426094,689.
Expected results:
Paste should enter the text from the clipboard.
Comment 1•5 years ago
|
||
Bugbug thinks this bug should belong to this component, but please revert this change in case of error.
Comment 2•5 years ago
|
||
[Parent 191584: Main Thread]: D/WidgetClipboard nsClipboard::HasDataMatchingFlavors (clipboard)
[Parent 191584: Main Thread]: D/WidgetClipboard no targes at clipboard (bad match)
[Parent 191584: Main Thread]: D/WidgetClipboard nsClipboard::HasDataMatchingFlavors (clipboard)
[Parent 191584: Main Thread]: D/WidgetClipboard no targes at clipboard (bad match)
[Parent 191584: Main Thread]: D/WidgetClipboard nsClipboard::HasDataMatchingFlavors (clipboard)
[Parent 191584: Main Thread]: D/WidgetClipboard has text/html
[Parent 191584: Main Thread]: D/WidgetClipboard nsClipboard::HasDataMatchingFlavors (clipboard)
[Parent 191584: Main Thread]: D/WidgetClipboard no targes at clipboard (bad match)
[Parent 191584: Main Thread]: D/WidgetClipboard nsClipboard::HasDataMatchingFlavors (clipboard)
[Parent 191584: Main Thread]: D/WidgetClipboard no targes at clipboard (bad match)
[Parent 191584: Main Thread]: D/WidgetClipboard nsClipboard::HasDataMatchingFlavors (clipboard)
[Parent 191584: Main Thread]: D/WidgetClipboard no targes at clipboard (bad match)
[Parent 191584: Main Thread]: D/WidgetClipboard nsClipboard::HasDataMatchingFlavors (clipboard)
[Parent 191584: Main Thread]: D/WidgetClipboard has kUnicodeMime
[Parent 191584: Main Thread]: D/WidgetClipboard nsClipboard::HasDataMatchingFlavors (clipboard)
[Parent 191584: Main Thread]: D/WidgetClipboard no targes at clipboard (bad match)
[Parent 191584: Main Thread]: D/WidgetClipboard nsClipboard::GetData (clipboard)
[Parent 191584: Main Thread]: D/WidgetClipboard Flavors which can be imported:
[Parent 191584: Main Thread]: D/WidgetClipboard text/unicode
[Parent 191584: Main Thread]: D/WidgetClipboard Getting unicode text/unicode MIME clipboard data
[Parent 191584: Main Thread]: D/WidgetClipboard nsRetrievalContextWayland::GetClipboardText [0x7f42d5988830]
[Parent 191584: Main Thread]: D/WidgetClipboard DataOffer::HasTarget() we have mime text/plain;charset=utf-8
[Parent 191584: Main Thread]: D/WidgetClipboard nsRetrievalContextWayland::GetClipboardData [0x7f42d5988830] mime text/plain;charset=utf-8
[Parent 191584: Main Thread]: D/WidgetClipboard DataOffer::GetData() mime text/plain;charset=utf-8
[1426096,480] -> wl_data_offer@4278190085.receive("text/plain;charset=utf-8", fd 153)
[Parent 191584: Main Thread]: D/WidgetClipboard failed to get unicode data
[Parent 191584: Main Thread]: D/WidgetClipboard failed to get clipboard content.
Looks like we can't read the fd 153 provided by compositor.
Updated•5 years ago
|
Comment 3•5 years ago
|
||
Could it be because of https://github.com/swaywm/sway/pull/5788 (part of https://github.com/swaywm/wlroots/issues/2421)?
GTK needs to be at 3.24.24. Ubuntu focal is at 3.23.20 and hirsute (next ubuntu) at 3.23.23 still. I don't know what distro and version (and sway version) the OP is at though.
The sway commit above is newer than 1.5. I compile master for myself and I've had to revert that particular commit for the time being as I'm on Ubuntu 20.04.
Comment 4•5 years ago
|
||
Just to clarify that patch breaks address bar copy/paste for me. Copy/paste from a website still works.
Comment 5•5 years ago
|
||
When you copy/paste from URL bar, you communicate with Firefox process directly.
Copy/paste from a website is similar to copy/paste from another application as web content uses separated process.
Comment 6•5 years ago
|
||
The primary selection may not be an issue here - there's zwp protocol for it.
Current version of Nightly 87.0a1 (2021-01-31) no longer has the problem. Closing this issue.
Description
•