Bug 474639 - Cannot launch ksmserver-logout-greeter when no global theme is set
Summary: Cannot launch ksmserver-logout-greeter when no global theme is set
Status: RESOLVED FIXED
Alias: None
Product: plasmashell
Classification: Plasma
Component: Session Management (show other bugs)
Version: master
Platform: Other Linux
: NOR major
Target Milestone: 1.0
Assignee: Plasma Bugs List
URL:
Keywords: qt6
: 478133 481321 (view as bug list)
Depends on:
Blocks:
 
Reported: 2023-09-18 00:31 UTC by Justin Zobel
Modified: 2024-04-06 15:57 UTC (History)
8 users (show)

See Also:
Latest Commit:
Version Fixed In: 6.0


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Justin Zobel 2023-09-18 00:31:46 UTC
I ran into this issue on my user and tested with "ksmserver-logout-greeter --windowed" and got the following error:
kde.logout_greeter: Couldn't find a theme for the Shutdown dialog ""

However, after setting a Global Theme in Look and Feel it worked fine.

I created a second user to see if it happened again and it did, so if there's no global theme set ksmserver-logout-greeter should fall back to an internal theme or if it can see Breeze on the system, use that.
Comment 1 Nate Graham 2023-09-18 18:35:52 UTC
Can confirm with a new user.
Comment 2 Niccolò Venerandi 2023-10-03 16:44:32 UTC
May I ask you if you find any way to reproduce this in an existing session? I'm having issues actually booting up my dev session, for some reason I only get a black screen, and this is slowing me down significantly. I'll try to fix that, but if you can find a way to repruce that is an existing session, it will make this significantly faster!
Comment 3 Nicolas Fella 2023-10-03 19:06:50 UTC
can you attach your .config/kdeglobals file?
Comment 4 Nicolas Fella 2023-10-03 19:15:44 UTC
as well as .config/kdedefaults/kdeglobals and "kreadconfig6 --file kdeglobals --group KDE --key LookAndFeelPackage"
Comment 5 Justin Zobel 2023-10-04 00:56:55 UTC
@Nicolas
.config/kdeglobals
[ColorEffects:Disabled]
ChangeSelectionColor=
Color=56,56,56
ColorAmount=0
ColorEffect=0
ContrastAmount=0.65
ContrastEffect=1
Enable=
IntensityAmount=0.1
IntensityEffect=2

[ColorEffects:Inactive]
ChangeSelectionColor=true
Color=112,111,110
ColorAmount=0.025
ColorEffect=2
ContrastAmount=0.1
ContrastEffect=2
Enable=false
IntensityAmount=0
IntensityEffect=0

[Colors:Button]
BackgroundAlternate=163,212,250
BackgroundNormal=252,252,252
DecorationFocus=61,174,233
DecorationHover=61,174,233
ForegroundActive=61,174,233
ForegroundInactive=112,125,138
ForegroundLink=41,128,185
ForegroundNegative=218,68,83
ForegroundNeutral=246,116,0
ForegroundNormal=35,38,41
ForegroundPositive=39,174,96
ForegroundVisited=155,89,182

[Colors:Complementary]
BackgroundAlternate=27,30,32
BackgroundNormal=42,46,50
DecorationFocus=61,174,233
DecorationHover=61,174,233
ForegroundActive=61,174,233
ForegroundInactive=161,169,177
ForegroundLink=29,153,243
ForegroundNegative=218,68,83
ForegroundNeutral=246,116,0
ForegroundNormal=252,252,252
ForegroundPositive=39,174,96
ForegroundVisited=155,89,182

[Colors:Header]
BackgroundAlternate=239,240,241
BackgroundNormal=222,224,226
DecorationFocus=61,174,233
DecorationHover=61,174,233
ForegroundActive=61,174,233
ForegroundInactive=112,125,138
ForegroundLink=41,128,185
ForegroundNegative=218,68,83
ForegroundNeutral=246,116,0
ForegroundNormal=35,38,41
ForegroundPositive=39,174,96
ForegroundVisited=155,89,182

[Colors:Header][Inactive]
BackgroundAlternate=227,229,231
BackgroundNormal=239,240,241
DecorationFocus=61,174,233
DecorationHover=61,174,233
ForegroundActive=61,174,233
ForegroundInactive=112,125,138
ForegroundLink=41,128,185
ForegroundNegative=218,68,83
ForegroundNeutral=246,116,0
ForegroundNormal=35,38,41
ForegroundPositive=39,174,96
ForegroundVisited=155,89,182

[Colors:Selection]
BackgroundAlternate=163,212,250
BackgroundNormal=61,174,233
DecorationFocus=61,174,233
DecorationHover=61,174,233
ForegroundActive=255,255,255
ForegroundInactive=112,125,138
ForegroundLink=253,188,75
ForegroundNegative=176,55,69
ForegroundNeutral=198,92,0
ForegroundNormal=255,255,255
ForegroundPositive=23,104,57
ForegroundVisited=155,89,182

[Colors:Tooltip]
BackgroundAlternate=239,240,241
BackgroundNormal=247,247,247
DecorationFocus=61,174,233
DecorationHover=61,174,233
ForegroundActive=61,174,233
ForegroundInactive=112,125,138
ForegroundLink=41,128,185
ForegroundNegative=218,68,83
ForegroundNeutral=246,116,0
ForegroundNormal=35,38,41
ForegroundPositive=39,174,96
ForegroundVisited=155,89,182

[Colors:View]
BackgroundAlternate=247,247,247
BackgroundNormal=255,255,255
DecorationFocus=61,174,233
DecorationHover=61,174,233
ForegroundActive=61,174,233
ForegroundInactive=112,125,138
ForegroundLink=41,128,185
ForegroundNegative=218,68,83
ForegroundNeutral=246,116,0
ForegroundNormal=35,38,41
ForegroundPositive=39,174,96
ForegroundVisited=155,89,182

[Colors:Window]
BackgroundAlternate=227,229,231
BackgroundNormal=239,240,241
DecorationFocus=61,174,233
DecorationHover=61,174,233
ForegroundActive=61,174,233
ForegroundInactive=112,125,138
ForegroundLink=41,128,185
ForegroundNegative=218,68,83
ForegroundNeutral=246,116,0
ForegroundNormal=35,38,41
ForegroundPositive=39,174,96
ForegroundVisited=155,89,182

[General]
ColorSchemeHash=6b5830f25b11af336f7ac15b36c5f0e793edd790

[WM]
activeBackground=227,229,231
activeBlend=227,229,231
activeForeground=35,38,41
inactiveBackground=239,240,241
inactiveBlend=239,240,241
inactiveForeground=112,125,138


.config/kdedefaults/kdeglobals
[General]
ColorScheme=BreezeLight


`kreadconfig6 --file kdeglobals --group KDE --key LookAndFeelPackage` shows a blank line.


@Niccolo I believe setting the above variable to blank would do the trick using kwriteconfig6.
Comment 6 Nicolas Fella 2023-10-04 16:23:24 UTC
I cannot reproduce this even with LookAndFeelPackage being empty
Comment 7 Nicolas Fella 2023-10-04 16:48:48 UTC
The code already falls back to the Breeze LookAndFeel when none is set, so that's not the issue
Comment 8 Nicolas Fella 2023-10-04 16:52:18 UTC
Does /usr/share/plasma/look-and-feel/org.kde.breeze.desktop/contents/logout/Logout.qml exist?
Comment 9 Bug Janitor Service 2023-10-04 16:53:08 UTC
A possibly relevant merge request was started @ https://invent.kde.org/plasma/plasma-workspace/-/merge_requests/3370
Comment 10 Justin Zobel 2023-10-05 01:11:02 UTC
(In reply to Nicolas Fella from comment #8)
> Does
> /usr/share/plasma/look-and-feel/org.kde.breeze.desktop/contents/logout/
> Logout.qml exist?

Yes, as it works on one user with a Global Plasma theme set, but not the other.
Comment 11 Nicolas Fella 2023-10-08 16:11:48 UTC
Git commit ce8d11695535dd5d8a729fb913b690ff9e1ef6c6 by Nicolas Fella.
Committed on 08/10/2023 at 17:59.
Pushed by nicolasfella into branch 'master'.

[logout-greeter] Print warning when LnF could not be loaded

M  +6    -0    logout-greeter/main.cpp

https://invent.kde.org/plasma/plasma-workspace/-/commit/ce8d11695535dd5d8a729fb913b690ff9e1ef6c6
Comment 12 Niccolò Venerandi 2023-10-09 14:41:48 UTC
I can't reproduce this either even with the provided instruction :-/
Comment 13 Nate Graham 2023-12-13 22:02:44 UTC
*** Bug 478133 has been marked as a duplicate of this bug. ***
Comment 14 Marco Martin 2023-12-14 13:03:15 UTC
note that also the distribution could alter the defaults by shipping global config files. here on opensuse for in stance, if i do have in kdeglobals
LookAndFeelPackage=
(with nothing after=, which tends to happens when explicitly setting breeze)

kreadconfig6 --file kdeglobals --group KDE --key LookAndFeelPackage  reads and empty line, but in this case to me it falls back correctly to breeze. on this machine.

if i remove the line LookAndFeelPackage=  instead kreadconfig6 reads "org.openSUSE.desktop"  and on plasma6 it will fail, as that opensuse theme is still for plasma5 only
Comment 15 Marco Martin 2023-12-14 13:39:12 UTC
I can image the above issue is involved in some way.

the lookandfeel package structure is done in a way that if an empty name is passed, breeze is always loaded as a fallback
Comment 16 vale.gualtieri3006 2024-02-14 17:47:19 UTC
*** Bug 481321 has been marked as a duplicate of this bug. ***
Comment 17 David Redondo 2024-02-21 11:24:39 UTC
Git commit da7385d61e32ba6746d2bcffc6675a2d70c858b6 by David Redondo.
Committed on 21/02/2024 at 11:00.
Pushed by davidre into branch 'master'.

lookandfeel packagestructure: Always fallback to default package

If a theme has no metadata.json (which can happen in the 5 to 6
transition period), we would end up with a valid package without
any fallback package. If such a package doesn't contain a certain
file we can now fall back.
Related: bug 480066

M  +3    -9    shell/packageplugins/lookandfeel/lookandfeel.cpp

https://invent.kde.org/plasma/plasma-workspace/-/commit/da7385d61e32ba6746d2bcffc6675a2d70c858b6
Comment 18 David Redondo 2024-02-21 11:24:56 UTC
Git commit 6cc49c68ff0e2d4d1ef7d67a47c7fe5ef9adf813 by David Redondo.
Committed on 21/02/2024 at 11:00.
Pushed by davidre into branch 'master'.

logout-greeter: Fallback to default lnf theme

If loading the file from the active lnf theme fails, also try
the fallback (default one).
FIXED-IN:6.0

M  +5    -0    logout-greeter/shutdowndlg.cpp

https://invent.kde.org/plasma/plasma-workspace/-/commit/6cc49c68ff0e2d4d1ef7d67a47c7fe5ef9adf813
Comment 19 David Redondo 2024-02-21 11:52:44 UTC
Git commit d928becd0646c77b25679f4829592a31034aef78 by David Redondo.
Committed on 21/02/2024 at 11:33.
Pushed by davidre into branch 'Plasma/6.0'.

lookandfeel packagestructure: Always fallback to default package

If a theme has no metadata.json (which can happen in the 5 to 6
transition period), we would end up with a valid package without
any fallback package. If such a package doesn't contain a certain
file we can now fall back.
Related: bug 480066

M  +3    -9    shell/packageplugins/lookandfeel/lookandfeel.cpp

https://invent.kde.org/plasma/plasma-workspace/-/commit/d928becd0646c77b25679f4829592a31034aef78
Comment 20 David Redondo 2024-02-21 11:52:45 UTC
Git commit 654bce7eeb6f401b0bf2f90595656c3a95e4bc49 by David Redondo.
Committed on 21/02/2024 at 11:33.
Pushed by davidre into branch 'Plasma/6.0'.

logout-greeter: Fallback to default lnf theme

If loading the file from the active lnf theme fails, also try
the fallback (default one).
FIXED-IN:6.0

M  +5    -0    logout-greeter/shutdowndlg.cpp

https://invent.kde.org/plasma/plasma-workspace/-/commit/654bce7eeb6f401b0bf2f90595656c3a95e4bc49