Execute Plugin not working

Suggest, post, or discuss plugins for Deluge
Post Reply
solai_4
New User
New User
Posts: 4
Joined: Wed Jul 28, 2021 10:41 am

Execute Plugin not working

Post by solai_4 »

Hi,

Running Deluge in Ubuntu 20.04 and when i try to run the sh script its not working. i'm running example script but getting below error. i tried restarting but still same issue.

When i execute the script in terminal is working fine, but not with deluge.
core:127 [execute] Running commands for complete
core:154 [execute] Execute script not found or not executable

Code: Select all

#!/bin/bash
torrentid=$1
echo "Torrent Details: " "$torrentid"  >> log.txt
deluged: 1.3.15
libtorrent: 1.1.5.0
mhertz
Moderator
Moderator
Posts: 2195
Joined: Wed Jan 22, 2014 5:05 am
Location: Denmark

Re: Execute Plugin not working

Post by mhertz »

The logging posted is pretty clear about reasoning - recheck path to script that you defined is correct and that script has execute bit correctly set. Should work then.
solai_4
New User
New User
Posts: 4
Joined: Wed Jul 28, 2021 10:41 am

Re: Execute Plugin not working

Post by solai_4 »

mhertz wrote: Wed Jul 28, 2021 1:40 pm The logging posted is pretty clear about reasoning - recheck path to script that you defined is correct and that script has execute bit correctly set. Should work then.
Copy pasted the exact location in terminal Running successfully in terminal but not by deluge. I could not find the reason.
mhertz
Moderator
Moderator
Posts: 2195
Joined: Wed Jan 22, 2014 5:05 am
Location: Denmark

Re: Execute Plugin not working

Post by mhertz »

Is script executable(you could run it in terminal with bash or sh preceding script name, though I'd guess you aren't but just to make absolutely sure). Also in terminal you're e.g in homedir and so relative path from there works, though not in deluge. Last, you're not using e.g tildes etc right, but straight up abselute full path correct. Also make sure script even readable by deluge running user, so if running deluge as deluge user, then try run script from terminal with sudo -u deluge PathToScript.
solai_4
New User
New User
Posts: 4
Joined: Wed Jul 28, 2021 10:41 am

Re: Execute Plugin not working

Post by solai_4 »

Found out the actual issue today. Location issue with the log file. when i replaced the log.txt with actual path for the log.txt fixed the issue.
mhertz
Moderator
Moderator
Posts: 2195
Joined: Wed Jan 22, 2014 5:05 am
Location: Denmark

Re: Execute Plugin not working

Post by mhertz »

Good find and thanks for posting back. Actually I was gonna previously test this, as I already thought the permissions wouldn't be in place to make new file(realized after replying to you), unless somehow current dir was deluge profile dir already, but just completelly forgot, and mainly probably because I was pretty sure wasent the actual issue here(but just wanted to exclude fully), as would show other error I.e just that script failed with non-zero exit code or something, and not like here that path not found, seeming very odd to me, but I'm glad you fixed it in end, but just think this was a seperate issue from the initial one honestly(of either no execute bit, or wrong path), but could be wrong.

I previously also checked(read) the execute plugin example you referenced using from the docs and they also use /tmp there as location for the file, which also was my first intention to use for my test as easy test for writeble location.
Post Reply