Bug 299073 - "Run script" from powermanager setting not parsed when leaving or entering profiles
Summary: "Run script" from powermanager setting not parsed when leaving or entering pr...
Status: RESOLVED WAITINGFORINFO
Alias: None
Product: solid
Classification: Unmaintained
Component: powermanagement-daemon (other bugs)
Version First Reported In: unspecified
Platform: Ubuntu Linux
: NOR normal
Target Milestone: ---
Assignee: Dario Freddi
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2012-04-30 03:46 UTC by goo
Modified: 2013-04-25 16:31 UTC (History)
4 users (show)

See Also:
Latest Commit:
Version Fixed/Implemented In:
Sentry Crash Report:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description goo 2012-04-30 03:46:11 UTC
In Powermanagement KCM if I supply a script under "Run Script" to be run either at the load or at the exit of the profile, it get not loaded when the specified event occurs.



Reproducible: Always

Steps to Reproduce:
1. kcmshell4 powerdevilprofilesconfig
2. Check "Run script" and supply a shell script in the script dialog, e.g, "/usr/local/bin/dpms-synergy.sh"
3.Wait for the time defined for some events to happen
Actual Results:  
The script is not run when the event occurs. Running inotifywait on the script file reveals that the script is not loaded at all.

Expected Results:  
the script should have been run.

KDE 4.8.2, Kubuntu 12.04
Comment 1 Jakub Zakrzewski 2012-06-06 13:24:06 UTC
I confirm this problem. It still occurs
on KDE 4.8.3, Kubuntu 12.04
Comment 2 Kai Uwe Broulik 2012-10-29 16:22:21 UTC
Cannot confirm on 4.9.2.
When I configure an action to run when loading the profile "AC", the command is executed when I plug in my AC cable.
Comment 3 Jakub Zakrzewski 2012-10-29 22:57:17 UTC
I don't use 4.9.2 yet, but if it is as Kai Uwe Broulik wrote, that's good. :)
Comment 4 Kai Uwe Broulik 2012-10-30 07:03:31 UTC
There hasn't been a change to the responsible file runscript.cpp since Nov 2010 though.
But judging from the code it should work. :)
Maybe there were some underlying changes to loading/triggering actions.
Comment 5 goo 2012-11-22 01:03:48 UTC
4.9.3 here and the bug is still reproduceable. :(

Anyway I have been trying to understand the meaning of "Profile" in the context of kcm powersaving, with no results. Where is the "profile" word mentioned besides the "run script" dialog?
I expected that "on profile load" refers to any triggered event listed, that is "dim display", "screen energy saving", "suspend session" or "button events handling", the latter not working here but that seems to be a distribution issue.
Comment 6 Jakub Zakrzewski 2012-11-22 01:27:53 UTC
Now I use kde 4.9.2. and the problem doesn't exist any longer for me.
Comment 7 Kai Uwe Broulik 2012-11-22 06:08:09 UTC
No, On Profile Load means that the script gets executed when the profile is being switched to, that is you plug in or out your AC adapter or your battery goes low, or you have configured some special behavior for an activity you switched to.
Comment 8 Alex Fiestas 2013-03-03 17:14:36 UTC
So, is this fixed?