Page 1 of 1

Issues with AMC on Deluge?

Posted: 01 May 2015, 23:54
by ivikd
Hello all, I've tried setting Deluge's execute function with the AMC script provided on the forums, but I don't think Deluge is actually running it, as nothing is written to the amc.log file. Here's the contents of my script:

Code: Select all

#!/bin/bash

TORRENT_ID=$1
TORRENT_NAME=$2
TORRENT_PATH=$3

filebot -script fn:amc --output "$HOME/Videos" --log-file amc.log --action move --conflict override -non-strict "ut_dir=$TORRENT_PATH/$TORRENT_NAME" "ut_kind=multi" "ut_title=$TORRENT_NAME" --def excludeList=amc.txt --def clean=y --def plex=127.0.0.1 --def unsorted=y
I've made sure the script has full read/execute permissions.
I don't know if it affects it, but the script is in /home/MainUser folders, would the default 'deluge' user have an issue with this?

Re: Issues with AMC on Deluge?

Posted: 02 May 2015, 06:59
by rednoah
What does this do?

Code: Select all

-$
Have you tried redirecting output to see what's going on?

Code: Select all

command1 > everything.txt 2>&1
@see http://www.cyberciti.biz/faq/linux-redi ... t-to-file/

Re: Issues with AMC on Deluge?

Posted: 02 May 2015, 15:23
by ivikd
rednoah wrote:What does this do?

Code: Select all

-$
Have you tried redirecting output to see what's going on?

Code: Select all

command1 > everything.txt 2>&1
@see http://www.cyberciti.biz/faq/linux-redi ... t-to-file/
Sorry about that, my script must've gotten cut off when I copied it, I've edited the post to include the rest of it.

Here's the output from running the command

Code: Select all

Locking /home/victor/.filebot/logs/amc.log
Parameter: excludeList = amc.txt
Parameter: clean = y
Parameter: plex = 127.0.0.1
Parameter: unsorted = y
Argument: /home/victor/ut_dir=
Argument: /home/victor/ut_kind=multi
Argument: /home/victor/ut_title=
File not found: /home/victor/ut_dir=
Failure (°_°)
As is expected, without passing $1, $2 and $3, the command fails. What bothers me, however, is that "ut_dir=" appears as an argument, is it supposed to be this way?

Re: Issues with AMC on Deluge?

Posted: 02 May 2015, 15:39
by rednoah
You're missing a --def to start the --def key=value argument sequence. Compare what your command to mine and you'll see the difference.

Re: Issues with AMC on Deluge?

Posted: 02 May 2015, 22:45
by ivikd
rednoah wrote:You're missing a --def to start the --def key=value argument sequence. Compare what your command to mine and you'll see the difference.
You're right, I've added it and the output now looks like what it's supposed to do, telling me it failed because no parameters were passed. However, it doesn't seem like Deluge is executing the script, or writing to the amc log. Could it have something to do with the way the users are set up?

EDIT: Nevermind, I've got it working now, I was testing it with the same file and it was getting excluded, I deleted the entry and it worked properly. Thanks a bunch, your script rocks!