Bug 389284

Summary: Screen lock notification does not work anymore
Product: [Frameworks and Libraries] frameworks-knotifications Reporter: Oleksandr Natalenko <oleksandr>
Component: generalAssignee: kdelibs bugs <kdelibs-bugs>
Status: RESOLVED FIXED    
Severity: normal CC: bhush94, kde, kde, kdelibs-bugs, kishore96, lnxusr, mgraesslin, plasma-bugs
Priority: NOR    
Version: unspecified   
Target Milestone: ---   
Platform: Arch Linux   
OS: Linux   
Latest Commit: Version Fixed In:

Description Oleksandr Natalenko 2018-01-21 16:04:39 UTC
Hi.

I was using "System settings — Notifications — Screen Saver — Screen locked" notification to execute a custom script, but since some last update it does not work anymore. If I run the script from the console manually, it works, of course.

I suppose this should be managed by ksmserver, and I have the configuration in place:

===
[~]$ cat .config/ksmserver.notifyrc 
[Event/locked]
Action=Execute
Execute=/usr/local/bin/lock.sh
Logfile=
Sound=
TTS=
===

but I have no idea how to debug this in order to gather more information.

Could you please give me some hint on this?
Comment 1 Kai Uwe Broulik 2018-01-22 09:04:31 UTC
The notification shows up for me but indeed a script isn't executed. It looks like the script execution itself is broken. Can you try with another notification and see if that works? Otherwise this is a bug in knotifications.
Comment 2 Oleksandr Natalenko 2018-01-22 17:18:50 UTC
(In reply to Kai Uwe Broulik from comment #1)
> The notification shows up for me but indeed a script isn't executed. It
> looks like the script execution itself is broken. Can you try with another
> notification and see if that works? Otherwise this is a bug in
> knotifications.

OK, I've just tried a notification on AC cable unplug: 1) playing a sound works; 2) executing a script doesn't work.
Comment 3 Kai Uwe Broulik 2018-01-23 13:34:04 UTC
Git commit 2690452736956f73c2348357e5e45b9f643e7f95 by Kai Uwe Broulik.
Committed on 23/01/2018 at 13:33.
Pushed by broulik into branch 'master'.

Fix loading NotifyByExecute

Looks like a copy paste error

CHANGELOG: The "Run Command" notification action has been fixed

Differential Revision: https://phabricator.kde.org/D10026

M  +1    -1    src/knotificationmanager.cpp

https://commits.kde.org/knotifications/2690452736956f73c2348357e5e45b9f643e7f95
Comment 4 Oleksandr Natalenko 2018-01-23 17:10:34 UTC
Confirming the fix, many thanks.
Comment 5 Christoph Feck 2018-02-16 00:25:17 UTC
*** Bug 390019 has been marked as a duplicate of this bug. ***
Comment 6 Rex Dieter 2018-02-16 17:45:41 UTC
*** Bug 390562 has been marked as a duplicate of this bug. ***