Bug 443737 - Corrupted login screen after update to 5.23
Summary: Corrupted login screen after update to 5.23
Status: RESOLVED FIXED
Alias: None
Product: plasmashell
Classification: Plasma
Component: Theme - Breeze (show other bugs)
Version: master
Platform: Other Linux
: VHI critical
Target Milestone: 1.0
Assignee: visual-design
URL:
Keywords: regression
Depends on:
Blocks:
 
Reported: 2021-10-14 18:45 UTC by Maksym
Modified: 2021-10-15 09:01 UTC (History)
4 users (show)

See Also:
Latest Commit:
Version Fixed In: 5.23.1


Attachments
Photo of corrupted login screen (384.36 KB, image/jpeg)
2021-10-14 18:45 UTC, Maksym
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Maksym 2021-10-14 18:45:54 UTC
Created attachment 142443 [details]
Photo of corrupted login screen

SUMMARY


STEPS TO REPRODUCE
1. Update KDE plasma to the 5.23.
2. On the login screen choose 'Other' option.
3. Try to login (example: to login with the user from LDAP).

OBSERVED RESULT
The password input is not present, it only has username input.
When you type your username and tried to login it fails (I assume because you the password should be specified)

EXPECTED RESULT
The password input should be present, I shpuld be abble to enter username and password and logged in to the system.

SOFTWARE/OS VERSIONS
Linux/KDE Plasma: KDE NEON
(available in About System)
KDE Plasma Version: 5.23.0
KDE Frameworks Version: 5.87.0
Qt Version: 5.15.3
Comment 1 Nate Graham 2021-10-14 21:16:24 UTC
Can confirm, darn. :( Looks like the password field has:

visible: userList.currentItem.needsPassword

and it's getting set to false or it's undefined for the case of LDAP users.
Comment 2 Nate Graham 2021-10-14 21:22:55 UTC
I don't see where we even set needsPassword. It's a writable property in UserDelegate.qml, but I can't find where it gets written to...
Comment 3 Nate Graham 2021-10-14 21:31:39 UTC
Clearly something is setting needsPassword to true sometimes or else login would be broken for everyone. Seems like this is a magic property set by SDDM itself; see https://github.com/sddm/sddm/issues/751#issuecomment-847347450.

I'm starting to worry that SDDM is broken and fails to set needsPassword to true for network users. If that's the case, we'll have to revert the feature until it's fixed.
Comment 4 Nate Graham 2021-10-14 21:42:38 UTC
Oh I'm dumb. it's because there is no `currentUser` in this case because the user needs to enter one first in user/password mode. We should simply disable this codepath for the username/password page.
Comment 5 Bug Janitor Service 2021-10-14 21:49:01 UTC
A possibly relevant merge request was started @ https://invent.kde.org/plasma/plasma-workspace/-/merge_requests/1118
Comment 6 Nate Graham 2021-10-14 22:03:05 UTC
Git commit f038ab3f494f26b443b10ff5dc9f156e1ec16341 by Nate Graham.
Committed on 14/10/2021 at 22:02.
Pushed by ngraham into branch 'master'.

sddm-theme: fix missing password field on "Other" page

On this page there is no concept of the user being passwordless because
no username has been specified by the user yet; we cannot know ahead of
time. As a result, userList.currentItem.needsPassword is blank so the
password field gets hidden.

We should just assume that in username/password entry mode, all users
have a password set. For any users where this is not the case, they can
just leave the password blank, and it's not any worse than it was in
Plasma 5.22.
FIXED-IN: 5.23.1

M  +2    -2    sddm-theme/Login.qml

https://invent.kde.org/plasma/plasma-workspace/commit/f038ab3f494f26b443b10ff5dc9f156e1ec16341
Comment 7 Nate Graham 2021-10-14 22:03:37 UTC
Git commit d5a3e749a30613294f41386180aaf31dfb1a9bee by Nate Graham.
Committed on 14/10/2021 at 22:03.
Pushed by ngraham into branch 'Plasma/5.23'.

sddm-theme: fix missing password field on "Other" page

On this page there is no concept of the user being passwordless because
no username has been specified by the user yet; we cannot know ahead of
time. As a result, userList.currentItem.needsPassword is blank so the
password field gets hidden.

We should just assume that in username/password entry mode, all users
have a password set. For any users where this is not the case, they can
just leave the password blank, and it's not any worse than it was in
Plasma 5.22.
FIXED-IN: 5.23.1


(cherry picked from commit f038ab3f494f26b443b10ff5dc9f156e1ec16341)

M  +2    -2    sddm-theme/Login.qml

https://invent.kde.org/plasma/plasma-workspace/commit/d5a3e749a30613294f41386180aaf31dfb1a9bee
Comment 8 Fabian Vogt 2021-10-15 09:01:17 UTC
(In reply to Nate Graham from comment #4)
> Oh I'm dumb. it's because there is no `currentUser` in this case because the
> user needs to enter one first in user/password mode. We should simply
> disable this codepath for the username/password page.

FTR, it works in the case that the "Other" page is the default, e.g. through SDDM's DisableAvatarsThreshold option.