flushaMeme / autokey

Automatically exported from code.google.com/p/autokey
GNU General Public License v3.0
0 stars 0 forks source link

dialog.* causes script error #224

Open GoogleCodeExporter opened 8 years ago

GoogleCodeExporter commented 8 years ago
What steps will reproduce the problem?

1. Create a simple script that pops a dialog window:

#Enter script code
dialog.info_dialog("Test", "Hello, world!")

(Any other type of dialog causes error as well.)

2. Assign a hotkey or phrase to the script; I used a hotkey.

3. Save.

What is the expected output? What do you see instead?

Script should pop a window with the given title and message.  Instead, no 
window pops and logging shows a script error (given below).

What version of the product are you using? On what operating system?

Autokey 0.90.4, KDE 4.8.5, Xubuntu 12.04

Please provide any additional information below.

Relevant log output:

2012-11-05 11:22:20,863 INFO - service - Matched hotkey phrase/script with 
prompt=False
2012-11-05 11:22:20,864 DEBUG - service - Script runner executing: 
Script('test')
2012-11-05 11:22:20,864 DEBUG - service - Ignored locking error in 
handle_keypress
2012-11-05 11:22:20,906 ERROR - service - Script error
Traceback (most recent call last):
  File "/usr/lib/python2.7/dist-packages/autokey/service.py", line 454, in execute
    exec script.code in scope
  File "<string>", line 2, in <module>
  File "/usr/lib/python2.7/dist-packages/autokey/scripting.py", line 259, in info_dialog
    return self.__runKdialog(title, ["--msgbox", message], kwargs)
  File "/usr/lib/python2.7/dist-packages/autokey/scripting.py", line 242, in __runKdialog
    p = subprocess.Popen(["kdialog", "--title", title] + args, stdout=subprocess.PIPE)
  File "/usr/lib/python2.7/subprocess.py", line 679, in __init__
    errread, errwrite)
  File "/usr/lib/python2.7/subprocess.py", line 1249, in _execute_child
    raise child_exception
OSError: [Errno 2] No such file or directory

Original issue reported on code.google.com by justin.y...@gmail.com on 5 Nov 2012 at 4:27

GoogleCodeExporter commented 8 years ago
Fixed it on Ubuntu by:
$ sudo apt-get install kde-baseapps-bin

Original comment by pratyush...@gmail.com on 11 Dec 2012 at 9:19

GoogleCodeExporter commented 8 years ago
Fixed it for me!  Thanks for posting this!

Original comment by justin.y...@gmail.com on 11 Dec 2012 at 6:36

GoogleCodeExporter commented 8 years ago
If it has not been done already, a bug needs to be filed in Ubuntu or even 
better upstream Debian to add a Depends on that package.

Original comment by Titan8...@gmail.com on 1 Mar 2013 at 5:42