[SDDM Theme] Offer switching to the user's session if there is one
AbandonedPublic

Authored by broulik on Oct 6 2016, 8:29 AM.

Details

Reviewers
davidedmundson
Group Reviewers
Plasma: Design
Plasma
Summary

When choosing "New Session" you get dumped on the login screen where there's no discoverable way (Ctrl+Alt+Fsomething isn't discoverable) to get back to the existing session and typing the password to log in will actually log the user in twice. This would essentially lock a novice user out from his or her session even if the screen was locked because "New Session" is accessible from there as well.

This patch changes the "Login" button with password field to a "Switch To" button in case there is already a graphical session of this user running.

Test Plan

Locked screen, chose "New Session", got a "Switch To" button for my user which upon clicking dropped me back into my existing session.

A difficulty we have is that when the session goes away, the login screen doesn't update because we never reload() the model - this is also true for the "Switch Session" button on the lock screen which only appears if tehre's another session. Is this something that is likely? Maybe somehow we could call reload() whenever the login screen gets switched to? I didn't test what happens if I actually log out from my session, ie. whether SDDM comes up after that or my session si still there for a brief moment which causes it to continue showing the "Switch To".

On one hand I'd like to have that in 5.8 (minus the "Switch To" we could just keep "Login" without the password field I support) as that's "how it should have been" but on the other hand this is a quite stark behavior change for a patch release.

This would also keep you from logging in with different sessions (eg. Gnome and Plasma) at the same time but I thinik logging into the same home dir with multiple graphical sessions is just surety for trouble.

Diff Detail

Repository
R120 Plasma Workspace
Lint
Lint Skipped
Unit
Unit Tests Skipped
broulik updated this revision to Diff 7137.Oct 6 2016, 8:29 AM
broulik retitled this revision from to [SDDM Theme] Offer switching to the user's session if there is one.
broulik updated this object.
broulik edited the test plan for this revision. (Show Details)
broulik added reviewers: Plasma, Plasma: Design.
broulik set the repository for this revision to R120 Plasma Workspace.
Restricted Application added a project: Plasma. · View Herald TranscriptOct 6 2016, 8:29 AM
Restricted Application added a subscriber: plasma-devel. · View Herald Transcript
broulik updated this revision to Diff 7138.Oct 6 2016, 8:30 AM

Apply similar patch like D2956 so pressing Return triggers the "Switch To" functionality if applicable

broulik edited the test plan for this revision. (Show Details)Oct 6 2016, 8:37 AM
broulik edited the test plan for this revision. (Show Details)Oct 6 2016, 8:41 AM
mart added a subscriber: mart.Oct 6 2016, 8:44 AM

+1000 from me \o/

colomar added a subscriber: colomar.Oct 6 2016, 9:50 AM

Definitely a good change!

Suggestion as for when to release: One way we could go about it is see whether we get bug reports about the current behavior. If users perceive it as a bug, we release this as a bugfix, otherwise it goes into 5.9.

davidedmundson requested changes to this revision.Oct 6 2016, 9:52 AM
davidedmundson added a reviewer: davidedmundson.
davidedmundson added a subscriber: davidedmundson.

The theme is not an appropriate place to do behavioural changes.

Otherwise you change theme and login is different.

Also it really needs to be a config option somewhere. People do multiple login. We made LightDM reuse sessions and got tonnes of comments.

This revision now requires changes to proceed.Oct 6 2016, 9:52 AM

Also it really needs to be a config option somewhere. People do multiple login. We made LightDM reuse sessions and got tonnes of comments.

@graesslin said he'd prefer to block multiple login with the same user due to all the issues it can cause. Can't people who are advanced enough to use multiple logins without problems also just go to a VT and start Plasma manually?

mart added a comment.Oct 6 2016, 10:22 AM

two sessions with the same login is something that is always bound to cause many problems.
returning to the same session should be at least the default, with some hoops to go trough in order to achieve the 2 logins for the same user.

romangg added a subscriber: romangg.EditedOct 14 2016, 4:47 PM

Is this Differential abandoned? I think the proposed behavioural change is greatly needed!

I'm doing some small work on the lock screen at the moment and while testing I created sometimes accidentally a second session of the same user in sddm, which always (!) locked up my PC completely and I had to hard reboot. Because of this I also don't think there should be a config option. Who does need a second GUI session on the same user anyway?

And as @broulik stated, the other big problem is, that a user isn't able to fall back via GUI to his old session once inside sddm. An accidental click on "Switch User" can happen and if the user is a Linux beginner, he might not know the concept of VTs and switching by Ctrl+Alt+Fx. Then disaster strikes as he tries to enter his old, but in fact new, user session in sddm.

If the theme isn't the right place to do this change, where can it go? To be honest I'm surprised it works this way at all, since I thought this has to be some hard coded functionality inside sddm.

In D2957#56665, @subdiff wrote:

Is this Differential abandoned? I think the proposed behavioural change is greatly needed!

If I'm too lazy to add this to SDDM before 5.9 we can push this. (and you can treat this comment as a ship it )

If I fix SDDM, then we won't need this.

Because of this I also don't think there should be a config option. Who does need a second GUI session on the same user anyway?

...you'd be surprised. Users are weird. But being weird doesn't mean we get to break their workflow on a whim.

LightDM didn't support login as the same user twice, I got a tonne of reports. One of the distros (red hat IIRC) even used that as a rationale for not switching.

broulik abandoned this revision.Nov 21 2016, 9:09 PM

i see this patch has been abandoned.. is there any follow-up on this? a google search led me here.
@davidedmundson mentions changing sddm but the only thing i found about that right now is the following issue:
https://github.com/sddm/sddm/issues/447
which already exists some time and does not seem like going to be fixed anytime soon? :/ or is this a whole different issue altogether?

thanks

sweet! any idea on when we could expect a release?