12

A few days ago I upgraded from 20.10 to 21.04. Since then Copy-paste sometimes(!) does not work.

It seemed random, but after some experimentation I think it is when I try to copy from Firefox to some other application. (The other application can be Chrome, VSCode, the terminal). The other application freezes for a few seconds and the paste does not work. However I can paste back to Firefox. Even more strangely, sometimes I can copy from Firefox to other applications as well.

Any idea what's going on?

sudo apt-get install firefox

firefox is already the newest version (88.0.1+build1-0ubuntu0.21.04.2).
szabgab
  • 265
  • 2
  • 9

2 Answers2

4

Ubuntu 21.04 uses Wayland by default, try to log out and make sure you are login using the Xorg/Xserver.

In the login page, look for an option to select which session you like to use. see this example pic login screen with drop-down having two options "Ubuntu" and "Ubuntu with Xorg"

Rabin
  • 156
  • 3
  • How can I do this? – szabgab May 19 '21 at 04:13
  • 2
    In the login page, look for an option to select which session you like to use. see this example pic - https://www.debugpoint.com/blog/wp-content/uploads/2021/04/wayland-in-Ubuntu-21.04.jpg – Rabin May 19 '21 at 09:27
  • 1
    Thanks. I switched to Xorg now. In a day or two I'll if it stops working again. – szabgab May 19 '21 at 14:07
4

So to answer your question

Any idea what's going on?

Firefox has reoccurring bugs when using it under Wayland (i.e. on modern Ubuntu or Fedora):

So you might follow these issues to be notified once it is fixed.

Until then you might indeed have to use X11 instead of Wayland.

alexanderadam
  • 909
  • 1
  • 8
  • 23
  • 1
    All of the listed issues have been closed, but the problem still persists (ubuntu 21.04 + firefix 90.0.2 here). A recent search https://bugzilla.mozilla.org/buglist.cgi?quicksearch=wayland+paste shows: 1722369 updated yesterday... – makeroo Jul 30 '21 at 10:39
  • Yes, that's true. The Mozilla devs claimed a few times that it should be fixed. And there was also a time where they claimed that it's not an FireFox issue. Some recent commits were referenced regarding this issues but these commits also have to land in the releases so keep the fingers crossed that one of them will actually fix this. – alexanderadam Jul 31 '21 at 15:29
  • 1
    On the Ubuntu side, this is the [bug 1913775](https://bugs.launchpad.net/ubuntu/+source/firefox/+bug/1913775) on Launchpad – Frédéric Grosshans Sep 22 '21 at 09:21
  • 3
    This ist still not working in Ubuntu 21.10 + Firefox 96.0. After a restart of Firefox it is working for some time, but after a while and a few copy & pastes it will stop working. Not working means that after copy from Firefox (e.g. address bar) and pasting into any other application, the paste target application will freeze for a few seconds (as if it gets flooded with rubbish data). On the up side, the workaround is to restart Firefox after the problem occurs and this will consistently fix it for a while for me. – Alexander Remesch Jan 25 '22 at 14:34