Bug 408714

Summary: Missing Clementine and Strawberry in System Settings -> Notifications -> Applications
Product: [Applications] systemsettings Reporter: Piotr Mierzwinski <piotr.mierzwinski>
Component: generalAssignee: Plasma Bugs List <plasma-bugs-null>
Status: RESOLVED DOWNSTREAM    
Severity: normal CC: kde, nate, piotr.mierzwinski
Priority: NOR    
Version First Reported In: 5.16.0   
Target Milestone: ---   
Platform: Arch Linux   
OS: Linux   
Latest Commit: Version Fixed/Implemented In:
Sentry Crash Report:
Attachments: System-Settings_Notifications_Application-Settings

Description Piotr Mierzwinski 2019-06-14 21:56:34 UTC
SUMMARY
Among others I have installed two music player applications like Clementine and Strawberry. Unfortunately no one of them is present in Applications list. I'm not sure if this is issue of these applications or bug in "Notifications -> Applications". Both are Qt5 applications, but this seems to be not reason, because VLC is present on mentioned list.
Please notice that notifications coming from Clementine are correctly handled by new notification system in Plasma - for example all played songs are collected in Notifications list and are showing notification window when is played new song.

STEPS TO REPRODUCE
1. Install Clementine and Strawberry
2. Call System Settings -> Notifications -> Applications
3. Try to find above applications

OBSERVED RESULT
Clementine and Strawberry are missing on the list.

EXPECTED RESULT
Clementine and Strawberry should be present on the list.

SOFTWARE/OS VERSIONS
Linux/KDE Plasma: YES
(available in About System)
KDE Plasma Version: 5.16
KDE Frameworks Version: 5.59
Qt Version: 5.12.3

ADDITIONAL INFORMATION
Comment 1 Nate Graham 2019-06-14 22:46:23 UTC
The first time one of them sends a notification, they should appear somewhere on what page. It might be in the Applications section, or it might be erroneously in the "System Services" section in which the apps will need to be patched (which is trivial).

Can you verify?
Comment 2 Piotr Mierzwinski 2019-06-14 23:09:02 UTC
"It might be in the Applications section"
What exactly option do you mean in this section?

Sorry, what do you mean saying '"System Services" section?
Where this section I can find? I don't see such in "System Settings". In "System Settings" I found only "Background Services", but I think this is not related with my issue.
Or maybe you mean modification file clementine.desktop?
Comment 3 Nate Graham 2019-06-15 00:09:34 UTC
I mean in System Settings > Notifications > Applications: Configure. Navigating there should show you a list of apps and system services that have provided notifications.
Comment 4 Piotr Mierzwinski 2019-06-17 20:50:07 UTC
Sorry, but I reported that on mentioned list Clementine and Strawberry are missing (neither in "Applications" nor in "System Services"). Typing "Cle" finding nothing.

I wonder what exactly is wrong with notifications provided by them. As I mentioned Clementine normally displays notifications in the new notifications system implemented in Plasma 5.16, and they are correctly collected by "Notifications".

I'm not sure what did you mean saying that "application need to be patched". Did you mean that patching is needed to change section (from "System Services" into "Applications") in this list?
Here the issue is that both mentioned applications are not visible on that list.
If this is possible please try to test it.
Comment 5 Piotr Mierzwinski 2019-06-17 20:57:21 UTC
Created attachment 120958 [details]
System-Settings_Notifications_Application-Settings
Comment 6 Kai Uwe Broulik 2019-06-18 09:40:47 UTC
Neither application seems to send a desktop entry with the notification.

Strawberry doesn't set a desktopFileName on its QApplication, so the QSystemTrayIcon it uses which creates a Plasma SNI through plasma-integration cannot send the desktop-entry hint when it does showMessage.

Clementine uses Qt4 which probably doesn't support any of this.

(I haven't compiled or tested either of those apps but quickly browsing the code suggests what I just wrote. Feel free to send them a bug report about this.)
Comment 7 Kai Uwe Broulik 2019-06-18 09:43:08 UTC
Looks like this was recently fixed for Clementine at least: https://github.com/clementine-player/Clementine/commit/8483d24a049618aafbc107f7869ee59746c19efa
Comment 8 Piotr Mierzwinski 2019-06-18 20:08:47 UTC
"Clementine uses Qt4 which probably doesn't support any of this."
I think Clementine long time ago has been ported into Qt5. 
In option "Help -> About Qt" I found: "This program uses Qt version 5.12.4."

Thanks for link to patch for Clementine.
I hope soon this fix will be available in my favorite Linux distribution.