Summary: | "switch user" does not list sessions | ||
---|---|---|---|
Product: | [Plasma] krunner | Reporter: | Edwin Schepers <yez> |
Component: | general | Assignee: | Plasma Bugs List <plasma-bugs> |
Status: | RESOLVED FIXED | ||
Severity: | major | CC: | amantia, crazy, facorread, jellenelis, jlp, kde-maintainers, marcus, stephaneguedon, sven.burmeister, t.powa, zander |
Priority: | NOR | ||
Version: | unspecified | ||
Target Milestone: | --- | ||
Platform: | unspecified | ||
OS: | Linux | ||
Latest Commit: | Version Fixed In: | ||
Sentry Crash Report: |
Description
Edwin Schepers
2007-11-23 22:39:24 UTC
Yep, same here, using build 3.96.2-8.3 (from the openSUSE Build Service) on openSUSE 10.3 *** Bug 153547 has been marked as a duplicate of this bug. *** Same here; built this morning with kdesvn-build. I can confirm this with Kubuntu/7.10 packages for KDE3.97. Lets up the severity; I think this functionality is basic enough to warrent it. Where does the responsibility for handling this lie? With Kickoff? The relevant code that handles it is within http://websvn.kde.org/trunk/KDE/kdebase/workspace/plasma/applets/kickoff/core/itemhandlers.cpp?view=markup at the LeaveItemHandler::switchUser() method. ...and it calls in http://websvn.kde.org/trunk/KDE/kdebase/workspace/krunner/interface.cpp?view=markup the Interface::switchUser() method :) here's the idea: krunner should show a list of the existing sessions. that's why there is a SessionRunner. apparently this either (a) never worked properly or (b) got broken since i first put that support in there. so look for special casing of the Sessions runner in krunner. Seems in SessionRunner::match(Plasma::SearchContext *search) the dm.localSessions(sessions) condition always fails here (KDE3 kdm). Reason is, that the DM::localSessions( SessList &list ) function in http://websvn.kde.org/trunk/KDE/kdebase/workspace/libs/kworkspace/dmctl.cpp?view=markup does always return false on exec at the if (!exec( "list\talllocal\n", re )) return false; The console output indicates that it's phonon/knotify that crashes; ksmserver(12056)/kdeui (KNotification) KNotificationManager::notificationClosed: 6 ksmserver(12056) KSMServer::logoutSoundFinished: Logout event finished ksmserver(12056) KSMServer::startKilling: Starting killing clients ksmserver(12056) KSMServer::startKilling: completeShutdown: client "kwinsmhelper" ( 10cd617274000119922427000000120560000 ) ksmserver(12056) KSMServer::startKilling: completeShutdown: client "knotify4" ( 10cd617274000119922427100000120560001 ) ksmserver(12056) KSMServer::startKilling: completeShutdown: client "krunner" ( 10cd617274000119922427100000120560002 ) ksmserver(12056) KSMServer::startKilling: completeShutdown: client "plasma" ( 10cd617274000119922427100000120560003 ) ksmserver(12056) KSMServer::startKilling: completeShutdown: client "klipper" ( 10cd617274000119922427300000120560004 ) ksmserver(12056) KSMServer::startKilling: completeShutdown: client "kaccess" ( 10cd617274000119922427300000120560005 ) ksmserver(12056) KSMServer::startKilling: We killed all clients. We have now clients.count()= 7 ksmserver(12056) KSMServer::completeKilling: KSMServer::completeKilling clients.count()= 7 ksmserver(12056)/kdeui (KNotification) KNotification::~KNotification: 6 knotify(12064)/phonon (xine backend) Phonon::Xine::XineEngine::~XineEngine: delete Phonon::Xine::AudioPortDeleter knotify(12064)/phonon (xine backend) Phonon::Xine::XineEngine::~XineEngine: delete QObject ksmserver(12056) KSMServer::completeKilling: KSMServer::completeKilling clients.count()= 6 ksmserver(12056) KSMServer::completeKilling: KSMServer::completeKilling clients.count()= 5 knotify(12064)/phonon (xine backend) Phonon::Xine::XineEngine::xineEventListener: XINE_EVENT_QUIT knotify(12064)/phonon (xine backend) Phonon::Xine::XineEngine::xineEventListener: XINE_EVENT_QUIT plasma(12067)/kio (KDirLister) KDirLister::stop: plasma(12067)/kio (KDirListerCache) KDirListerCache::forgetDirs: KDirLister(0x779da8) item moved into cache: KUrl("file:///home/kde4/Desktop") ksmserver(12056) KSMServer::completeKilling: KSMServer::completeKilling clients.count()= 4 ksmserver(12056) KSMServer::completeKilling: KSMServer::completeKilling clients.count()= 3 plasma(12067) Plasma::LayoutItem::setLayout: layout removed from under us. expect crashes plasma(12067) Plasma::LayoutItem::setLayout: layout removed from under us. expect crashes plasma(12067) Plasma::LayoutItem::setLayout: layout removed from under us. expect crashes plasma(12067) Plasma::LayoutItem::setLayout: layout removed from under us. expect crashes plasma(12067) Plasma::LayoutItem::setLayout: layout removed from under us. expect crashes plasma(12067)/kio (KDirListerCache) KDirListerCache::~KDirListerCache: -KDirListerCache ksmserver(12056) KSMServer::completeKilling: KSMServer::completeKilling clients.count()= 2 knotify(12064)/phonon (xine backend) Phonon::Xine::AudioPortData::~AudioPortData: ----------------------------------------------- audio_port destroyed knotify(12064)/phonon (xine backend) Phonon::Xine::XineEngine::~XineEngine: delete Phonon::Xine::AudioPortDeleter knotify(12064)/phonon (xine backend) Phonon::Xine::XineEngine::~XineEngine: delete QObject KCrash: crashing... crashRecursionCounter = 2 KCrash: Application Name = knotify4 path = <unknown> pid = 12064 sock_file=/home/kde4/.kde4/socket-earth/kdeinit4__3 Interesting here that we have 2 times "Phonon::Xine::XineEngine::~XineEngine" ... seems here to disable the sound for the logout-notification fixes the crash. *uarg* sorry, my reply above was designed to land at another report. I can confirm this bug using the simplelauncher use from kickoff also. Still has stuck around in 4.0.0 Well that shouldn't surprise anyone, but yeah. *** Bug 155463 has been marked as a duplicate of this bug. *** Yep, like Jonathan Thomas said, the bug's still around. I'm using a completely fresh install from the openSUSE Build Service, so I'm pretty sure it's code and not something on my machine messed up from countless upgrades (like my previous lack of keyboard shortcuts) Yep, the bug's still alive. what you wanted was the "add cc" field to the right... er, I don't know if you need bugzilla rights in order for it to show up. I'll add you. Could Calvin Mitchell please fix his mail or get removed from this bug? (Removing bouncing CC'ed.) I am not spammer or spam source ! Even if I have my own postfix server ! Thanks ... Le mardi 22 janvier 2008 à 23:44 +0000, Calvin Mitchell a écrit : [bugs.kde.org quoted mail] i can confirm this issue in opneSUSE Aplha1 and KDE 4.0.0 Please stop confirming! Everybody knows this feature is missing, there is no need to spam this report with "I can confirm". Uff, that problem is really a mess :-/ So, I got some steps future. I am running KDM from KDE3 and use an own kde4-account where I installed KDE4 under. 1. running "kdmctl" at the prompt of the kde4-user should provide a list of some stuff. If it says permission denied, like it did in my case, you may need to switch some permissions at "/var/run/xdmctl/dmctl-:0" or whatever directory kdmctl complains about (thanks goes to Ossi here for providing that hint at the KDE4 release-party :) 2. check what echo "$DM_CONTROL" says. In my case it was needed to "export DM_CONTROL=/var/run/xdmctl" and now in kdebase/workspace/libs/kworkspace/dmctl.cpp in the DM::DM() ctor the if (::connect( fd, (struct sockaddr *)&sa, sizeof(sa) )) condition is true what results in fd = -1; beeing set what in turn means, that in the DM::localSessions() method the if (!exec( "list alllocal\n", re )) is true aka it fails to fetch the sessions :-/ So, question is now, why ::connect( fd, (struct sockaddr *)&sa, sizeof(sa)) fails here. I don't see any difference to http://websvn.kde.org/branches/KDE/3.5/kdebase/kdmlib/dmctl.cpp?view=markup Part of the problem is that KRunner resets its interface *completely* if the search term is empty. This is why the "Switch users" header appears and disappears after 200ms. A workaround (or the solution?) is to use display("SESSIONS"); instead of display() in krunner/interface.cpp:429. This makes sure the sessions are listed. Creating new sessions works, switching to existing one does not. I use kdm from KDE3 though, but IMO it should work there as well. BTW, the search term must be "SESSIONS", otherwise the sessions will not be listed. And if you delete the sessions term, KRunner resets itself and the header is changed to the standard KRunner header... Sincerely I find using KRunner for sessions switching a bad idea. Hehe: void SessionRunner::exec(Plasma::SearchMatch * action) { if (!action->data().toString().isEmpty()) { //TODO: implement session switching here! return; } ... } SVN commit 769905 by amantia: Make session switching work. If there are no problems (and there should not be), I will backport. BUG: 152805 M +2 -2 interface.cpp M +12 -1 runners/sessions/sessionrunner.cpp WebSVN link: http://websvn.kde.org/?view=rev&revision=769905 This bug seems to have returned in trunk! I just tried it out, and once again, "Switch User" just opens the KRunner dialog (without "SESSIONS" filled in). I just tested with trunk from ~3 hours ago, and it works. And there were no commits to krunner meantime. > Sincerely I find using KRunner for sessions switching a bad idea.
all the problems you note are solely due to the UI not being completed. the plan is to have all vs single runner and editable vs fixed query. then all else goes away.
of course, one could also put the list of sessions in kickoff as well by using the runner to populate a page.
> all the problems you note are solely due to the UI not being
> completed. the plan is to have all vs single runner and editable vs
> fixed query. then all else goes away.
In that case it makes more sense. :)
Now if I could find out why SESSIONS is not always kept a sa search
term...
*** Bug 157451 has been marked as a duplicate of this bug. *** Aaron, I saw that runners were moved/changed in trunk. Do you plan to backport those changes to branch? If not, I'd like to backport the session switching part to branch, so 4.0.2 will have it. @Andras: if you'd like to do the backport of the sessions runner (even just the .cpp file, doesn't need to be the whole "make it a plugin" bit) that would be great. it was already on my backporting TODO, but that's already a long list and i've got tons of other things to keep me happily occupied as it is ;) anyways, let me know if you get to it and i'll just scratch it off my list with a little "I Love Andras" sticker next to it... Actually I was thinking of backporting only the session switching code. I don't think I'd dare to backport all the changes you done in trunk to the runners, because well, there would be a high risk of breaking something. :) But we'll see what I can do. the changes in SessionsRunner::match are all seem safe enough.. but yes, backport whatever subset of changes you'd like to =) Am I getting old? I checked the commit messages and I *did* backport it on 4th of February, 4 days before writing comment #33. :) I don't have time to help with the rest of the backport of therunners code, as I don't have a KDE 4.0 system running, just trunk, and I wouldn't dare to do the backport without actually checking that everything works as it should. we're all getting older ... all the time ;) if you need/want testing of 4.0 branch things, just let me know. i've set up a 4.0 checkout here. Let's reopen this as it is still buggy. If you log in, the feature will not work, "SESSIONS" appears and disappears. As soon as you restart krunner (killall krunner;krunner) it will work. This makes hard to debug it, because as soon as you make a change in krunner and you restart it, it will work... Just a note that it is still present in trunk. SVN commit 830312 by aseigo: fix session listing BUG:152805 M +2 -0 krunner/interface.cpp M +2 -0 plasma/runners/sessions/sessionrunner.cpp WebSVN link: http://websvn.kde.org/?view=rev&revision=830312 |