Bug 458356

Summary: Plasma 5.25.x not launching on FreeBSD
Product: [Plasma] kactivitymanagerd Reporter: Tobias C. Berner <tcberner>
Component: generalAssignee: Ivan Čukić <ivan.cukic>
Status: RESOLVED DUPLICATE    
Severity: normal CC: a.samirh78, grahamperrin, nate, plasma-bugs
Priority: NOR    
Version: 5.25.4   
Target Milestone: ---   
Platform: Other   
OS: FreeBSD   
Latest Commit: Version Fixed In:
Sentry Crash Report:

Description Tobias C. Berner 2022-08-26 20:00:51 UTC
SUMMARY

It seems there is a change 5.25.x that makes plasma-shell not coming up properly on FreeBSD.

In the terminal, I can see 

```
Aborting shell load: The activity manager daemon (kactivitymanagerd) is not running.
```

STEPS TO REPRODUCE
1. Install KDE Plasma 5.25.4 on FreeBSD
2. execute startx


OBSERVED RESULT
Plasma shell startup starts (turning gear). 
But stays there for ever.




EXPECTED RESULT
Normal startup....


SOFTWARE/OS VERSIONS 
FreeBSD/KDE Plasma:  14-Current/5.25.4
(available in About System)
KDE Plasma Version:  5.25.4
KDE Frameworks Version: 5.97
Qt Version: 5.15.5

ADDITIONAL INFORMATION
Executing `plasmashell --replace` in the broken state gets you a working desktop.
Comment 1 Graham Perrin 2022-08-28 12:00:21 UTC
Thank you, 

(In reply to Tobias C. Berner from comment #0)

> … Executing `plasmashell --replace` in the broken state …

Should this have a similar effect? 

pkill plasmashell && plasmashell

I sometimes run that (with KRunner) if the desktop does not appear following a round of updates. On this occasion, it did not have the required effect, however things seemed to be OK after simply logging out then in. 

----

Operating System: FreeBSD 14.0
KDE Plasma Version: 5.24.6
KDE Frameworks Version: 5.97.0
Qt Version: 5.15.5
Kernel Version: 14.0-CURRENT (64-bit)
Graphics Platform: X11
Memory: 15.9 GiB of RAM
Graphics Processor: AMD TURKS

% uname -aKU
FreeBSD mowa219-gjp4-8570p-freebsd 14.0-CURRENT FreeBSD 14.0-CURRENT #19 main-n257401-82493ff7007a: Tue Aug 16 05:16:20 BST 2022     grahamperrin@mowa219-gjp4-8570p-freebsd:/usr/obj/usr/src/amd64.amd64/sys/GENERIC-NODEBUG amd64 1400065 1400065
% 

– I'm aware that 1400065 is slightly outdated, I'll update.
Comment 2 Graham Perrin 2022-08-29 01:02:45 UTC
Please ignore my comment #1> KDE Plasma Version: 5.24.6

– I didn't realise until after posting, the version in my case is inferior. Apologies for the noise.
Comment 3 Ahmad Samir 2022-08-30 18:56:52 UTC
Does moving ~/.local/share/kactivitymanagerd (before starting plasmashell), make any difference?
Comment 4 Tobias C. Berner 2022-09-02 09:19:10 UTC
Moin moin 

I could verify that the kactivitymangerd process is up and running (in the broken state):
> ps ax | grep kactivitymanagerd
3723  -  S     0:00.10 /usr/local/lib/libexec/kactivitymanagerd

It also provides the DBus interface:
> /usr/local/lib/qt5/bin/qdbus  org.kde.ActivityManager                                                                                                                                          
/
/ActivityManager
/ActivityManager/Activities
/ActivityManager/Features
/ActivityManager/Resources
/ActivityManager/Resources/Linking
/ActivityManager/Resources/Scoring
/MainApplication
/SLC
/Templates
/org
/org/kde
/org/kde/ActivityManager
/runner
Comment 5 Tobias C. Berner 2022-09-02 09:21:56 UTC
(In reply to Ahmad Samir from comment #3)
> Does moving ~/.local/share/kactivitymanagerd (before starting plasmashell),
> make any difference?

Moin moin 

No difference, unfortunately.

mfg Tobias
Comment 6 Tobias C. Berner 2022-09-16 17:52:08 UTC
@Ivan, could you point me to any possible fix for this? Or where I might start to bisect the issue?
Comment 7 Ivan Čukić 2022-09-16 18:27:12 UTC
What does it mean kactivitymanagerd is running 'in the broken state'?

Are you able to run 
qdbus org.kde.ActivityManager /ActivityManager/Activities ListActivities 
and get something?

If you got the result, and you do
qdbus org.kde.ActivityManager /ActivityManager/Activities AddActivity "TestActivity"
does ListActivities return one item more?

If all these work, try out
kactivities-cli --list-activities
and see if it gives a normal output.
Comment 8 Tobias C. Berner 2022-09-16 18:39:18 UTC
This is the output after the commands:

> qdbus-qt5 org.kde.ActivityManager /ActivityManager/Activities ListActivities'
29c58aa6-6cee-4a30-a39f-848fd9c41311
9aa45efa-e1ea-4c73-81d6-a7bf58913125

> qdbus-qt5 org.kde.ActivityManager /ActivityManager/Activities AddActivity TestActivity'
a3cba20c-27fa-41fd-82ad-618add682f7d

> kactivities-cli --list-activities
[CURRENT] 29c58aa6-6cee-4a30-a39f-848fd9c41311 Standard ()
[RUNNING] 9aa45efa-e1ea-4c73-81d6-a7bf58913125 TestActivity ()
[RUNNING] a3cba20c-27fa-41fd-82ad-618add682f7d TestActivity ()
Comment 9 Tobias C. Berner 2022-09-16 18:40:13 UTC
(In reply to Ivan Čukić from comment #7)
> What does it mean kactivitymanagerd is running 'in the broken state'?

That the shell-startup claims "kactivity-managerd" is not running, but the dbus-service seems to be present, so it seems to be running .
Comment 10 Ivan Čukić 2022-09-16 18:58:16 UTC
Ok, so it is functioning properly, is just plasma that doesn't see it from what I can tell. When you're in a window like Konsole, press Alt+F3 to show the KWin menu, do you have the activities submenu there?

The only time when I saw something similar to this was when somehow one application had access to one dbus service, and another application to another dbus service, so they didn't see each other.
Comment 11 Tobias C. Berner 2022-09-16 19:06:53 UTC
(In reply to Ivan Čukić from comment #10)
> Ok, so it is functioning properly, is just plasma that doesn't see it from
> what I can tell. When you're in a window like Konsole, press Alt+F3 to show
> the KWin menu, do you have the activities submenu there?

Yes, the menu seems to be present and populated:
https://people.freebsd.org/~tcberner/patches/kactivity-menu.png
Comment 12 Tobias C. Berner 2022-09-29 15:01:40 UTC
(In reply to Ivan Čukić from comment #10)
> Ok, so it is functioning properly, is just plasma that doesn't see it from
> what I can tell. When you're in a window like Konsole, press Alt+F3 to show
> the KWin menu, do you have the activities submenu there?
> 
> The only time when I saw something similar to this was when somehow one
> application had access to one dbus service, and another application to
> another dbus service, so they didn't see each other.

@ivan, any idea on how to resolve the issue?
Comment 13 Ivan Čukić 2022-09-29 19:39:47 UTC
Were you able to check if kwin and plasma are running somehow in different environments? I'm not a BSD guy, I can't really help there.

You could patch plasma to log somewhere the list of dbus services it sees after the message that kamd is not found for debugging purposes. To see why it thinks kamd is not there.
Comment 14 Nate Graham 2024-12-17 21:33:55 UTC

*** This bug has been marked as a duplicate of bug 466193 ***