Opened 11 years ago

Closed 11 years ago

#1289 closed defect (Fixed)

Execute plugin broken

Reported by: konti Owned by:
Priority: major Milestone: 1.3
Component: Plugin Version: 1.3.0_dev
Keywords: Cc: silviemeis@…

Description

Configuring the execute plugin doesn't work. Tested with .sh and .py scripts. Scripts don't get executed.

execute.conf:

{
  "file": 1,
  "format": 1
}{
  "commands": [
    [
      "5cc6d491c5f8a21ee676feac31852355fa96dedc",
      "Torrent Complete",
      "/var/lib/deluge/scripts/notify_xbmc_complete.sh"
    ],
    [
      "dc9db2645da61fbb4c5a68723d22bf7b70186934",
      "Torrent Added",
      "/var/lib/deluge/scripts/test.py"
    ]
  ]
}

test.py

#!/usr/bin/python
import sys
import os
import syslog
#syslog.syslog('syslog junkie: the script has just got woken up')
# some code
for arg in sys.argv[1:]:
    syslog.syslog(arg)

Also mentioned in topic: http://forum.deluge-torrent.org/viewtopic.php?f=9&t=31445

Change History (4)

comment:1 Changed 11 years ago by konti

  • Cc silviemeis@… added

comment:2 follow-up: Changed 11 years ago by konti

Configuring from the webui i got the following execute.cfg

{
  "file": 1,
  "format": 1
}{
  "commands": [
    [
      "5cc6d491c5f8a21ee676feac31852355fa96dedc",
      "Torrent Complete",
      "/var/lib/deluge/scripts/test_complete.sh"
    ],
    [
      "dc9db2645da61fbb4c5a68723d22bf7b70186934",
      "Torrent Added",
      "/var/lib/deluge/scripts/test_started.py"
    ]
  ]
}

By stopping the daemons, changing "Torrent Complete" to "complete" and "Torrent Added" to "added", starting the daemons, the problem was solved. It calls both scripts now.

comment:3 in reply to: ↑ 2 Changed 11 years ago by konti

Replying to konti:

By stopping the daemons, changing "Torrent Complete" to "complete" and "Torrent Added" to "added", starting the daemons, the problem was solved. It calls both scripts now.

After some more testing i found out that it only works for 50% now. When torrents start it calls the test_started.py script when a torrent completes it also calls the test_started.py script. test_complete.sh is never called. So "added" seems to be triggerd in both situations.

comment:4 Changed 11 years ago by damoxc

  • Resolution set to fixed
  • Status changed from new to closed

This has now (finally) been fixed in git, so will be in rc2!

Note: See TracTickets for help on using tickets.