** Description changed:

- Use case:
- 1. install gnome-session or gnome-classic or unity, you will end up with 
additional xorg session.
- 2. Log in on a system you don't have wayland capability
+ [Impact]
  
- -> you will be fallback to a random xorg session, being vanilla gnome,
- or ubuntu-xorg, or gnome-classic or even unity.
+ Users upgrading to artful on a system that cannot run wayland may be
+ logged into an unexpected session at the next boot.
  
- -> we should insert "-xorg" flavor for current session on fallback to
- get that one on the stack and ensuring we possibly fallback to a
- compatible session.
+ 
+ [Steps to reproduce]
+ 
+ 1. On a system with wayland capability, log into the "Ubuntu" session.
+ 2. Install gnome-session if it wasn't already installed (this adds two 
sessions, "GNOME" and "GNOME on Xorg").
+ 3. Disable wayland (uncomment WaylandEnable=false in /etc/gdm3/custom.conf) 
and reboot.
+ 
+ Expected result: at the greeter, the "Ubuntu on Xorg" session is
+ selected by default (falling back from "Ubuntu" to "Ubuntu on Xorg").
+ 
+ Actual result: at the greeter, the "GNOME on Xorg" session is selected
+ by default.
+ 
+ 
+ [Fix]
+ 
+ The fix consists in using the default fallback mechanism in gdm3, i.e. 
/usr/share/wayland-sessions/ubuntu.desktop falls back to 
/usr/share/xsessions/ubuntu.desktop, adding corresponding "-xorg.desktop" 
session files, and having gdm3 ignore them under wayland. This was discussed 
and approved upstream (https://bugzilla.gnome.org/show_bug.cgi?id=788552).
+ The fix involves a distro-patch in gdm3 (already merged upstream, will go 
away with the next release) and changes to the packaging of gnome-session 
(added symlinks).
+ 
+ 
+ [Test Case]
+ 
+ see [Steps to reproduce]
+ 
+ 
+ [Regression Potential]
+ 
+ The gdm3 patch has been thoroughly tested and merged upstream. Since
+ this is C glib code, reviewers should carefully look for possible memory
+ leaks, as strings are being allocated.
+ 
+ If a package installs /usr/share/xsessions/foo-xorg.desktop without a
+ corresponding /usr/share/xsessions/foo.desktop, the session will be
+ ignored if wayland is disabled. It is however considered a standard
+ practice that foo-xorg is a fallback for foo, so it wouldn't make much
+ sense to have the former without the latter.
+ 
+ In case of a partial upgrade:
+  - only gdm3 upgraded: nothing user-visible should happen, as gdm will ignore 
the foo-xorg session only if the corresponding foo session file exists
+  - only gnome-session upgraded: with wayland disabled, at the greeter the 
user might see two sessions that are in fact the same thing: "Ubuntu" and 
"Ubuntu on Xorg" (but logging into any of the two will work)
+ 
+ One minor gotcha with this patch: if, with wayland enabled, one intentionally 
selects ubuntu-xorg, then disables wayland, then reboots, in the login screen 
no session is selected in the dropdown (because gdm ignored ubuntu-xorg). 
However this will still launch the ubuntu-xorg session by default (which 
effectively is the same as the ubuntu session), so all is good (except for the 
fact that no session appears selected in the dropdown). This has the advantage 
of retaining the "ubuntu-xorg" session selected by the user if wayland is 
re-enabled later, though.
+ This is a regression in the sense that no session is visually selected in the 
dropdown, but it doesn't affect the default session selection.

-- 
You received this bug notification because you are a member of Ubuntu
Desktop Bugs, which is subscribed to gdm3 in Ubuntu.
https://bugs.launchpad.net/bugs/1718446

Title:
  Ensure wayland -> xorg fallback to the corresponding session

To manage notifications about this bug go to:
https://bugs.launchpad.net/gdm/+bug/1718446/+subscriptions

-- 
desktop-bugs mailing list
desktop-bugs@lists.ubuntu.com
https://lists.ubuntu.com/mailman/listinfo/desktop-bugs

Reply via email to