BUG - GNOME won't load Wayland session with latest Nvidia 381.22 drivers + Ubuntu GNOME 17.04

SUMMARY
I’ve been talking with the GNOME DE community as well as devs, and they say everything is set in place to load gnome-shell under Wayland (see the bug report I submitted to GNOME here: [url]https://bugzilla.gnome.org/show_bug.cgi?id=781075[/url]). They said the issue lies in the Linux Nvidia driver itself.

BEHAVIOR
When you boot into Ubuntu (GNOME) 17.04, the GNOME login screen (GDM) has a gear button with different session options to load after login. Wayland, the new display server, is GNOME’s default session. When the NVidia 381.22 drivers are installed, GNOME only shows 2 out of 3 of the session options. The user can’t load a GNOME session under Wayland, only X11/Xorg.

EXPECTED BEHAVIOR
Even after the Nvidia 381.22 drivers are installed on Ubuntu 17.04, the user should be able to log in with their username and password, and - with the “GNOME” option selected in the gear button - GNOME should load under the Wayland display server.

BUG DISCOVERED USING
Ubuntu GNOME 17.04 x64
GNOME / GDM 3.24.1
Linux kernel 4.10.0-21-generic
Nvidia 381.22 proprietary drivers via ppa:graphics-drivers/ppa
Nvidia GTX 1080 graphics card
X.org 1.19.3
Wayland-protocols (package version 1.7-1)

Other Ubuntu GNOME users have apparently had this issue as well, though this post has a few more Nvidia-centric details like my bug report link that I think can help: [url]nvidia - No way to choose wayland in GDM using UbuntuGNOME 17.04 - Ask Ubuntu

Same issue on gnome 3.24.

Same here.

Ubuntu 17.10
GeForce GTX 960
Linux kernel 4.13.0
GNOME Shell 3.26.1
Wayland

You probably need to have the nvidia driver running with modeset=1 for wayland to work, and this is not the default for the nvidia driver. There is lots of discussion on how to get the nvidia driver working with modeset=1 on the Prime Sync thread, since it’s a requirement for that technology too.

But it still won’t work. gdm and nvidia with modeset=1 is a ton of misery in my experience.