This is the situation I have now. I see this screen when powering the PC with a window on the left that is cut in half.
When I enter the password I now get a black screen. Yes, you read it correctly.
I've tried all this already:
joaquim@joaquim-HTPC:~$ sudo apt-get purge xfce4
Reading package lists... Done
Building dependency tree... Done
Reading state information... Done
The following packages were automatically installed and are no longer required:
exfalso fonts-font-awesome fonts-lato fonts-symbola gir1.2-gst-plugins-base-1.0 gir1.2-gtksource-3.0 gir1.2-keybinder-3.0 gstreamer1.0-gtk3 hyphen-en-us
libgtksourceview-3.0-1 libgtksourceview-3.0-common libkeybinder-3.0-0 libreoffice-gtk3 libreoffice-help-common libreoffice-help-en-us libxfce4ui-utils mythes-en-us
python3-feedparser python3-musicbrainzngs python3-mutagen python3-pyinotify python3-sgmllib3k quodlibet sphinx-rtd-theme-common tango-icon-theme task-desktop
xfce4-appfinder xfce4-panel xfce4-pulseaudio-plugin
Use 'sudo apt autoremove' to remove them.
The following packages will be REMOVED:
task-xfce-desktop* xfce4*
0 upgraded, 0 newly installed, 2 to remove and 0 not upgraded.
After this operation, 25,6 kB disk space will be freed.
Do you want to continue? [Y/n] Y
(Reading database ... 235459 files and directories currently installed.)
Removing task-xfce-desktop (3.68ubuntu2) ...
Removing xfce4 (4.16) ...
joaquim@joaquim-HTPC:~$ sudo apt install ubuntu-gnome-desktop
Reading package lists... Done
Building dependency tree... Done
Reading state information... Done
The following additional packages will be installed:
gnome-session
The following NEW packages will be installed:
gnome-session ubuntu-gnome-desktop
0 upgraded, 2 newly installed, 0 to remove and 0 not upgraded.
Need to get 17,9 kB of archives.
After this operation, 153 kB of additional disk space will be used.
Do you want to continue? [Y/n] Y
Get:1
http://archive.ubuntu.com/ubuntu jammy/universe amd64 gnome-session all 42.0-1ubuntu2 [15,2 kB]
Get:2
http://archive.ubuntu.com/ubuntu jammy/universe amd64 ubuntu-gnome-desktop amd64 0.92 [2758 B]
Fetched 17,9 kB in 0s (43,1 kB/s)
Selecting previously unselected package gnome-session.
(Reading database ... 219017 files and directories currently installed.)
Preparing to unpack .../gnome-session_42.0-1ubuntu2_all.deb ...
Unpacking gnome-session (42.0-1ubuntu2) ...
Selecting previously unselected package ubuntu-gnome-desktop.
Preparing to unpack .../ubuntu-gnome-desktop_0.92_amd64.deb ...
Unpacking ubuntu-gnome-desktop (0.92) ...
Setting up gnome-session (42.0-1ubuntu2) ...
Setting up ubuntu-gnome-desktop (0.92) ...
joaquim@joaquim-HTPC:~$ sudo apt install tasksel
[sudo] password for joaquim:
Reading package lists... Done
Building dependency tree... Done
Reading state information... Done
tasksel is already the newest version (3.68ubuntu2).
tasksel set to manually installed.
0 upgraded, 0 newly installed, 0 to remove and 0 not upgraded.
joaquim@joaquim-HTPC:~$ sudo apt-get remove --auto-remove tasksel
Reading package lists... Done
Building dependency tree... Done
Reading state information... Done
The following packages will be REMOVED:
tasksel tasksel-data
0 upgraded, 0 newly installed, 2 to remove and 0 not upgraded.
After this operation, 365 kB disk space will be freed.
Do you want to continue? [Y/n] Y
(Reading database ... 219037 files and directories currently installed.)
Removing tasksel-data (3.68ubuntu2) ...
Removing tasksel (3.68ubuntu2) ...
Processing triggers for man-db (2.10.2-1) ...
joaquim@joaquim-HTPC:~$ sudo apt-get purge --auto-remove tasksel
Reading package lists... Done
Building dependency tree... Done
Reading state information... Done
The following packages will be REMOVED:
tasksel*
0 upgraded, 0 newly installed, 1 to remove and 0 not upgraded.
After this operation, 0 B of additional disk space will be used.
Do you want to continue? [Y/n] Y
(Reading database ... 219011 files and directories currently installed.)
Purging configuration files for tasksel (3.68ubuntu2) ...
and it looks as if I don't have any desktop...
joaquim@joaquim-HTPC:~$ echo $XDG_CURRENT_DESKTOP
joaquim@joaquim-HTPC:~$