Summary: | [PATCH] Fix plugin loading in kate sessions | ||
---|---|---|---|
Product: | [Applications] kate | Reporter: | Hemant Kumar <gethemant> |
Component: | sessions | Assignee: | KWrite Developers <kwrite-bugs-null> |
Status: | RESOLVED FIXED | ||
Severity: | critical | CC: | a.vanloon, aacid, alex.oleshkevich, annma, beat_fasel, david.mike.simon, dmitry.risenberg, g4mba5, gskbyte, hein, iksdrijf, illissius, jl, kilolima, ltwilliams58, lucas, markrose, massimo.landozzi, Michael.McTernan, msnkipa, MurzNN, nik, nzimas, pickscrape, projects.gg.aaron, ralph, steffenjost, sucker_pvn, travier, will.angenent, william.brandino, wouter-kde, zoom_re |
Priority: | VHI | ||
Version: | unspecified | ||
Target Milestone: | --- | ||
Platform: | Ubuntu | ||
OS: | Linux | ||
Latest Commit: | Version Fixed In: | ||
Attachments: |
Save plugin configuration in the active session
Save unnamed sessions to katerc |
Description
Hemant Kumar
2008-01-21 19:45:15 UTC
Hi, I agree to that behaviour, but the behaviour is a little bit more complex. 1) I enabled a couple of plugins, Kate crashes when closing (see also #156559) I deleted ~/.kde4/share/apps/kate/.. Afterwards I could close without crashing. 2) On my Box I can open Kate from Menu and it remembers the enabled plugins. When I open it from e.g. dolphin (by clicking on a text file) kate does not remember the plugins. Also ubuntu 7.10 Best Regards Created attachment 23518 [details]
Save plugin configuration in the active session
AFAICT, this happens because plugin configuration is saved in the global
configuration file, but loaded from the session. This patch fixes the problem
for me, by saving plugin configuration into the session file.
Thanks for the patch. Needs review wrt session management. I confir this bug! I think the plugin configuration should be independent of sessions. I don't use sessions, but I would like to have the plugin select on my next use. Best regards Status on patch review? *** Bug 177026 has been marked as a duplicate of this bug. *** I also confirm this bug Suse11.1 64, KDE4.1.3, Kate 3.1.3: All plugins are deactivated when loading a previously saved session. Highly annoying. This bug is also present in KDE 4.2.0 (Ubuntu Intrepid 64 bit). *** Bug 192839 has been marked as a duplicate of this bug. *** related: bug #156100 *** Bug 183297 has been marked as a duplicate of this bug. *** *** Bug 200612 has been marked as a duplicate of this bug. *** Not sure it's related. kate started in console gives following output when forgetting plugin kttsd. Calling appendChild() on a null node does nothing. kdesdk-4.2.4-1.fc11.i586, Fedora Core 11 is also afflicted - Kate rapidly forgets the plugins when using sessions, and also loses the associated keyboard shortcuts. So for kdesdk-4.2.4-1.fc11.i586, I've worked out at least one reproducible cause of plugin's being lost which matches Steffan Jost's report on this bug. The problem comes when you login and KDE tries to restore the previous session by running "kate -session <some long number>". Under this condition the plugin settings are not loaded. Specifically I find 3 possible locations for the settings, all which have the konsole plugin enabled: $ locate "*.katesession" | xargs grep plugin=true /home/mmcternan/.kde/share/apps/kate/default.katesession:kateexternaltoolsplugin=true /home/mmcternan/.kde/share/apps/kate/default.katesession:katefindinfilesplugin=true /home/mmcternan/.kde/share/apps/kate/default.katesession:katekonsoleplugin=true /home/mmcternan/.kde/share/apps/kate/default.katesession:katesnippetsplugin=true /home/mmcternan/.kde/share/apps/kate/sessions/DPCCH%20Searcher.katesession:kateexternaltoolsplugin=true /home/mmcternan/.kde/share/apps/kate/sessions/DPCCH%20Searcher.katesession:katefindinfilesplugin=true /home/mmcternan/.kde/share/apps/kate/sessions/DPCCH%20Searcher.katesession:katekonsoleplugin=true /home/mmcternan/.kde/share/apps/kate/sessions/DPCCH%20Searcher.katesession:katesnippetsplugin=true /usr/share/kde4/apps/kate/default.katesession:katefilebrowserplugin=true /usr/share/kde4/apps/kate/default.katesession:katefindinfilesplugin=true /usr/share/kde4/apps/kate/default.katesession:katekonsoleplugin=true Kate doesn't show any plugins when started with -session. Then, when exiting kate, the defaults are saved back, removing the plugins for subsequent sessions. As a workaround I've made my default settings file read-only (chmod a-w). Now the settings are still not loaded when KDE restores my last desktop session, but exiting kate doesn't nuke my default config; closing and reopening kate gets the plugins back again. Kate is a really nice editor with great features, but this losing of settings is driving me insane. I hope it can be fixed soon. (In reply to comment #15) > So for kdesdk-4.2.4-1.fc11.i586, I've worked out at least one reproducible > cause of plugin's being lost which matches Steffan Jost's report on this bug. > > The problem comes when you login and KDE tries to restore the previous session > by running "kate -session <some long number>". Under this condition the plugin settings are not loaded. I can confirm this behavior on KDE 4.3, except that there is no such an option "-session" in kate from KDE 4.3 - there is "-s", which is short form of "--start". If i start kate from console: # kate -s "Default Session" all plugins are loaded ok. But something intrudes, when session manager tries to restore KDE session on login. Kate session restored, but without plugins. So it is probably not a Kate bug > Kate doesn't show any plugins when started with -session. Then, when exiting > kate, the defaults are saved back, removing the plugins for subsequent > sessions. > > As a workaround I've made my default settings file read-only (chmod a-w). Now > the settings are still not loaded when KDE restores my last desktop session, > but exiting kate doesn't nuke my default config; closing and reopening kate > gets the plugins back again. > > Kate is a really nice editor with great features, but this losing of settings > is driving me insane. I hope it can be fixed soon. *** Bug 203372 has been marked as a duplicate of this bug. *** *** Bug 206014 has been marked as a duplicate of this bug. *** On Kate 3.3.1, enabled plugins are *NOT* shown in the UI after a previously saved session is reopen, although the checkboxes to activate them appear ticked in Configure Kate > Plugins. KDE: 4.3.1 Kate: 3.3.1 Distribution: PCLinuxOS It's still there. Having to go to the configuration dialog each time I start my system to enable the terminal plugin is really an annoying bug. am i correct in stating that this bug has been around all the way through intrepid and jaunty? I don't know about Ubuntu, but as it's still present in Debian unstable as of today, it might very well be. AFAICT, the root of this problem is the default session missing. The solution should be that kate should load a virtual default session, if the user does not select one, and store your settings there. (In reply to comment #23) > AFAICT, the root of this problem is the default session missing. > > The solution should be that kate should load a virtual default session, if the > user does not select one, and store your settings there. I'm not sure this is it. When I copy my saved session over the default session and then run Kate, the plugins still don't come: $ pwd ~/.kde/share/apps/kate $ cp sessions/Kate.katesession default.katesession $ kate ... still no plugins until I manually load the 'Kate' session through Sessions->Manage... select my 'Kate' session and then click Ok. Maybe if it's never going to be fixed, the session stuff can be disabled/removed? I'd prefer a single config if it can remember my config from the last run. Michael.McTernan.2001: "Maybe if it's never going to be fixed, the session stuff can be disabled/removed? I'd prefer a single config if it can remember my config from the last run." I agree 100% with this. This bug has prevented any of our developers from following me to Karmic. I've had no choice but to use KDevelop and pursuit other editors until this is remedied :-( As with all bugs I'm tracking (eg KNetworkManager), I have seen little to no developer input. Where are the developers? (In reply to comment #25) > As with all bugs I'm tracking (eg KNetworkManager), I have seen little to no > developer input. Where are the developers? developers still struggling with vim, no time for some second-league editor :\ (joking, of course. i'm totally agree with free sw's "if you don't like it, fix it youself". This bug is not so irritating for me, due to lack of really useful plugins) In upcoming KDE 4.4 Kate will always save the session config. The options were removed what to do on exit (i.e. no ask, no not-safe). (In reply to comment #27) > In upcoming KDE 4.4 Kate will always save the session config. The options were > removed what to do on exit (i.e. no ask, no not-safe). Does it supposed to fix this bug? An is this change already included in kde 4.4 beta2 ? does anyone know of a kate nightly binary build that we could subscribe to? that would save us *buntu people from 6 months of angst :) thanks *** Bug 177240 has been marked as a duplicate of this bug. *** I am confused what reply #27 means. The bug is still there in KDE 4.4 final as released for openSuse 11.2. (The version number reads KDE 4.4.00 "release 224".) I confirm that plugins are still disabled when restoring sessions in KDE 4.4.0 (Mandriva 2010.0). Using name sessions works. When not using sessions, it only works if you invoke Sessions > Save as Default. This is also why the report is still open. (In reply to comment #33) > Using name sessions works. When not using sessions, it only works if you invoke > Sessions > Save as Default. This is also why the report is still open. in kde 4.4.0 this still does not work even using sessions: testcase: 1) open few documents in kate 2) in settings enable some plugins (filebrowser, for ex.) - filebrowser tab should appear in one of dockareas 3) save this as a session with some name ('mysession', for ex.) 4) logout and login back - kate restored opened files, and session name 'mysession:' can be seen in window title. but no plugins are enabled. *** Bug 229827 has been marked as a duplicate of this bug. *** *** Bug 210492 has been marked as a duplicate of this bug. *** I've got the same prolem with kate 3.4.1 on KDE 4.4.1 with an Arch Linux box. Kate should save the session and close when I logout (suspend to ram raises the same problem) and restore previous session at statup. I can confirm this bug under Kubuntu 9.10 using latest KDE4.4.2. *** Bug 237590 has been marked as a duplicate of this bug. *** *** Bug 240441 has been marked as a duplicate of this bug. *** This bug still exists using Kate 3.4.5 (under Kubuntu Lucid Lynx, 64-bit). Confirming under 3.4.2 64bit Kubuntu Lucid Lynx KDE 4.4.2 Kate Part 3.4 The (old) Bug #173283 reported in <https://bugs.launchpad.net/ubuntu/+source/kdebase/+bug/173283> is I guess related(?). Comment #10 in this report is the solution. Cheers, Nikos Just to avoid confusions: apologies for ignoring the auto-linking feature to comments and bug reports within "bugs.kde.org". All references in (previous) comment number 43 are related to a report in launchpad (in the provided full-link of course). Not related in my case: all my KDE configuration files have the right permissions. With Mandriva 2010.1 and KDE 4.4.3, Kate does not reload plugins at session restoration. But it does when quitting it and lauching it again. Sorry to read that gambas. It fixed for me the issue(s). (In reply to comment #46) > Sorry to read that gambas. It fixed for me the issue(s). In my case this is also unrelated. All permissions are fine. I have no permission issues, described in https://bugs.launchpad.net/ubuntu/+source/kdebase/+bug/173283 post #10, but have the problem with plugin loading. System is Kubuntu Lucid, KDE 4.4. KDE 4.5 Beta2 have this issue too. When I enable plugins and quit kate, starts again - enabled plugins are disabled. Doing "Sessions > Save Session as Default" solve the problem for me. In comment #27 the developer mentioned that in KDE 4.4 Kate will always save the session config so that this problem will be solved. However, with KDE 4.5.1 I still experience this bug. I was wondering if there is an updated time frame on when this bug is going to get fixed? *** Bug 243972 has been marked as a duplicate of this bug. *** Created attachment 52863 [details] Save unnamed sessions to katerc The attached patch is an attempt to eliminate the default.katesession file again. Instead, all config data is saved to katerc. Additionally, "Session > Save as Default" is removed. On Kate exit, an unnamed session is saved to katerc. Please try this patch: 1. first checkout the development version http://kate-editor.org/get-it/ 2. then apply the patch in your checkout with: patch -p1 < default-session-in-katerc.patch 3. compile/install kate and then run it with the run.sh script. Questions: 1. Does that fix the plugin loading bug? 2. Are there other _new_ problems introduced with this change? *** Bug 116511 has been marked as a duplicate of this bug. *** *** Bug 240313 has been marked as a duplicate of this bug. *** *** Bug 211601 has been marked as a duplicate of this bug. *** The patch is committed to gitorious now: http://gitorious.org/kate/kate/commit/c75047e756e5b2db99d410fdc3ee13a57a4b3060 This removes the default.katesession and merges it back into the katerc config file. Unnamed sessions are read and written back to katerc. This way, changes in the plugin settings and the recent-files-menu are saved. Please test this thoroughly by simply following http://kate-editor.org/get-it/ , so we can be sure it's working for KDE 4.6! *** Bug 227497 has been marked as a duplicate of this bug. *** *** Bug 198866 has been marked as a duplicate of this bug. *** SVN commit 1191600 by cullmann: dhaumann: fix bug #156330: lugin loading in kate sessions This removes the default.katesession and merges it back into the katerc config file. Unnamed sessions are read and written back to katerc. This way, changes in the plugin settings and the recent-files-menu are saved. Please test this thoroughly, so we can be sure it's working for KDE 4.6! BUG: 156330 M +2 -2 app/kateapp.cpp M +4 -1 app/kateconfigdialog.cpp M +0 -4 app/katemainwindow.cpp M +10 -41 app/katesession.cpp M +4 -15 app/katesession.h M +1 -1 data/CMakeLists.txt D data/default.katesession M +0 -4 data/kate.desktop M +30 -1 data/katerc M +0 -1 data/kateui.rc WebSVN link: http://websvn.kde.org/?view=rev&revision=1191600 I wonder if I should open a new bug since the behavior that got me here persists in Kate 3.10.3 on KDE 4.10.3 Yes, please report a new bug, with exact steps to reproduce. This is not solved. Occur with frequence when changes sessions. Ubuntu 16.04 - Version 15.12.3 |