Page 1 of 1

[help] utorrent integration

Posted: 05 Mar 2013, 10:09
by 1C9C5C9FD24C5BD946
not working.

filebot.log

Code: Select all

Parameter: music = y
Parameter: subtitles = en
Parameter: artwork = y
Parameter: ut_dir = %D
Parameter: ut_file = %F
Parameter: ut_kind = %K
Parameter: ut_title = %N
Parameter: ut_label = %L
Parameter: ut_state = %S
Done ?(?????)?

Re: [help] utorrent integration

Posted: 05 Mar 2013, 10:18
by rednoah
Why did you not copy the cmdline call into utorrent? Where did you think the %variables get replaced with actual values?

Re: [help] utorrent integration

Posted: 05 Mar 2013, 10:44
by 1C9C5C9FD24C5BD946
I did exactly what you said. It didn't work so I tried using the command line, because I don't know how to run commands as programs or users like in linux. All I changed was the output.

Re: [help] utorrent integration

Posted: 05 Mar 2013, 12:15
by rednoah
Well, seems to run fine, as good as it gets without any input anyway.

What's not working when run from utorrent? What command is utorrent executing? See utorrent logger tab. See troubleshooting section for more info. It's probably one of the issues I describe in the Notes section.

Re: [help] utorrent integration

Posted: 05 Mar 2013, 12:38
by 1C9C5C9FD24C5BD946
yep, just as i suspected. utorrent run a program isnt working, i set it to internet explorer to test it. its not working. go figure.

Re: [help] utorrent integration

Posted: 05 Mar 2013, 12:43
by rednoah
Windows? Mac? What's it say in the logger tab?

Re: [help] utorrent integration

Posted: 05 Mar 2013, 12:53
by 1C9C5C9FD24C5BD946
I got it to work. My only other question is how do i let couchpotato know that the movie is done, so it can move it from wanted to manage?

Re: [help] utorrent integration

Posted: 05 Mar 2013, 13:07
by rednoah
Not sure. Does couchpotatoe have an API? How would it normally know a torrent is done?

Re: [help] utorrent integration

Posted: 05 Mar 2013, 13:14
by 1C9C5C9FD24C5BD946
Yes, it does have an api. I have honestly never used it with utorrent. I used to use it with nzb. I would have to say, after 30 mins of googling. I have no clue. I'll ask couchpotato.

EDIT: For anyone else interested, I will be continuing this here. https://couchpota.to/forum/thread-1586.html

Re: [help] utorrent integration

Posted: 14 Mar 2013, 19:30
by sfted999
1C - how did you get the utorrent run command to work? I'm having the same problem. Logger says executing and does nothing/never finishes.

Re: [help] utorrent integration

Posted: 14 Mar 2013, 19:47
by rednoah
If the command doesn't seem to work it's usually because of PATH setup issues. Most probably one of the issues already highlighted in the Notes section.

Re: [help] utorrent integration

Posted: 14 Mar 2013, 20:09
by sfted999
Thanks for the reply. So after a little playing on my side, I was able to get UTorrent to execute notepad.exe when a torrent is complete, but the filebot command line sticks at executing. If I take the same command line and pump it through command prompt, all works well with successful output. I suspected UAC, but I had that turned off already. I also tried running as administrator but had the same result.

Re: [help] utorrent integration

Posted: 14 Mar 2013, 20:12
by rednoah
Is it stuck or just not working at all? utorrent will call a 32-bit compatibility mode command prompt so ENVIRONMENT and PATH may be different from when you're testing with normal 64-bit command prompt.

Re: [help] utorrent integration

Posted: 14 Mar 2013, 20:21
by sfted999
As far as I can tell, it's not working. I never get a failure, but I don't get any output piped to the text file either. How can I check the 32-bit environmental variables?

Re: [help] utorrent integration

Posted: 14 Mar 2013, 21:14
by rednoah
Try setting an absolute path to filebot.cmd in utorrent and then modify filebot.cmd and set an absolute path to java.exe

Re: [help] utorrent integration

Posted: 04 Jan 2014, 01:05
by johbra365
Hi,

have the exact same problem with utorrent integration. Works fine with command prompt but utorrent dont seem to execute. Tried running as admin but no difference. Did you have any luck with suggestion about utorrent running compability command promt? What format did you end up using for path?

//Johan

Re: [help] utorrent integration

Posted: 04 Jan 2014, 07:35
by rednoah
If you have PATH issues (e.g. 'filebot' command not found) try using the absolute path to the executable, e.g. "C:/Program Files/Filebot/filebot.exe" or "./Applications/Filebot.app/Contents/MacOS/filebot.sh"

Re: [help] utorrent integration

Posted: 10 Apr 2014, 09:10
by venloth
I'm having a similar issue to this. I tried running the script directly in space provided for "run program when torrent completed", I tried running it directly to a .bat file that i made for the script. The logger isn't even saying anything about even trying to execute it. I'm not really sure what's going on... seeing that "filebot" works just fine in command prompt. I can even double click the .bat and i can see it open up command prompt and run it. So I don't understand why utorrent isn't using it.

EDIT: I just tried running the .bat file after taking out the variables and putting in an input path and it ran through command prompt just fine. The only thing it didn't seem to do was clean up the files it left behind. If it helps at all this is the code that I'm running.

Code: Select all

filebot -script fn:amc --output "E:/DownloadsT/Organized" --log-file amc.log --action copy --conflict auto -non-strict --def music=y subtitles=en excludeList=amc.txt clean=y "ut_label=%L" "ut_state=%S" "ut_title=%N" "ut_kind=%K" "ut_file=%F" "ut_dir=%D"

Re: [help] utorrent integration

Posted: 10 Apr 2014, 13:25
by rednoah
You can't just "run a .bat file" ... how do you think the %variables get resolved? Hint: They don't. But that's only an issue once utorrent actually calls anything at all. Check the Logger tab. It definitely does something.

Re: [help] utorrent integration

Posted: 10 Apr 2014, 17:26
by venloth
If i can't just "run a .bat file" how come when I double clicked it, it ran. And I did say that when I ran it I took out the variables and replaced them with an input... seeing as I realize the variables are specifically for utorrent so the script knows what it is looking for. BUT... I downloaded a torrent and, unlike last night, this morning it does say
"Executing: E:/Utorrent-Filebot script.bat".
So maybe I misunderstood what you were referring to when you said that I can't just run a .bat file. So... since utorrent says that it is executing the file, but it isn't actually doing anything. Where am I doing it wrong? Is the script supposed to be a different type of file? Is it just supposed to stay the UTF8 "File"? Or is the script supposed to be directly in the "run program after torrent finishes" line like I tried in the first place?

Re: [help] utorrent integration

Posted: 11 Apr 2014, 05:08
by rednoah
Well, have you tried following my instructions? What's the issue? I can't remember writing anything about .bat files. ;)

PS: .bat files are not executables, and it only looks like they are because the Windows Shell runs the .bat files with cmd.exe, kinda like .txt files are "run" with editor.exe, if .bat can work in utorrent really depends on if utorrent is smart enough to not actually execute the .bat file, but execute cmd.exe with the given .bat file as argument.

PS2: Scripting on Windows is riddled with pitfalls and just sucks in general. That's why my instructions nowadays completely avoid any usage of Windows CMD and .bat files.

Re: [help] utorrent integration

Posted: 11 Apr 2014, 17:14
by venloth
For the most part I'm pretty sure I followed your instructions. The issue is what others on this thread have been having. It said it would execute that .bat file. But after your last message I'm going to try a .exe file now and I will try the original "filebot" command but I will try the absolute path again. I didn't realize that utorrent wouldn't be able to execute a .bat file. I threw the script back into gedit, saved as a UTF8 file and added .exe at the end to change the file type. I'm going to try this and play around a little bit and see what the logger tells me. Do I have to restart utorrent or my comp every time I change the run program file destination?

EDIT 1: Just thought I'd give you updates. First try, I changed the run program destination to the .exe file with the script. Restarted and when I opened Utorrent I saw "NOTE: Settings file found in directory of executable; using that.". Now I got excited thinking that was a good sign so I went and found something to download, downloaded it, and when finished Utorrent didn't even say anything about executing the destination file.

EDIT 2: Tried the .txt file with the script in it. The logger said it executed the file and nothing after that. No movement of the downloaded file and nothing new in the output folder. Going to go back and try the .exe file again, see if utorrent will try to execute that this time or not. If not I will have to accept that a UTF8 file turned to .exe file just isn't acceptable with utorrents run program feature. If that doesn't work I will go through and try absolute paths to filebot.

EDIT 3 = FINAL: OK so apparently I am completely retarded. I kept seeing everyone working with having utorrent actually execute a file with the script in it. Before I decided to start messing with the absolute pathing of the script I thought I'd try putting the script directly into the run program. It worked... I think my IP might have just been banned forever
Banned *IP address" until forever
so I don't really know what that means... BUT I GOT IT TO WORK ONCE!

EDIT 3.1 = FINAL: Alright, I'm not exactly sure why but when I double checked with a second download the script didn't run. The logger said nothing about it at all again. And it doesn't appear to be me that I got banned, seems to be a peer (I'm assuming) that got banned. On a second download to double check that it is working I saw that multiple times. I just realized though... The script is running, It is moving the files to the correct folder and organizing them and pulling subtitles for them. But It still doesn't seem to be cleaning the old files or folders after it moves. Is the command in my script incorrect or in the wrong place for the cleaner to work?

I opened the advanced settings in the "Add New Torrent" window and I was wondering... shouldn't whatever is in the "Run this program when the download finishes" line show up here too?

It seems to be working on... like... every other torrent for some reason. Some it'll execute for and others it won't.

I am going to stop editing at this point, I'll keep trying different downloads to see if it works again. I don't want to completely overload you when you finally get to see this and inform me how ignorant I really, truly am when it comes to this. :?

Re: [help] utorrent integration

Posted: 11 Apr 2014, 18:25
by rednoah
I stopped reading the above after there was something of renaming some file to .exe to make it executable


0. do not create any files, do not rename any extensions, do not paste any text into files, do not touch any files at all

1. Watch the video tutorial, which follows exactly the instructions:
https://www.youtube.com/watch?v=a10vTV- ... t&index=12

Note that there is never ever EVER any .bat .exe .whatever files created in this process.

2. Restart your computer once. Then make sure the command "filebot" works. It'll look like this:
http://snag.gy/ZXPj7.jpg

If it says "command not found" google how to add programs to the path.

Re: [help] utorrent integration

Posted: 11 Apr 2014, 18:36
by venloth
Ok. I watched the video... I actually stumbled my way to figuring out that the script goes directly in that line. As I was editing my previous post I mentioned that I did this and it executed on my first download. I tried several more after that and for some reason it only executes about ever other file. Reading your post it seems that it might be because I haven't restarted my computer so I am going to go ahead and do that right now and try with another few - several files.

I was also really interested in why my clean=y command isn't deleting residual files left behind after the rename and move. I was curious if it was because the command was in the wrong place or incorrectly put into the script. I appreciate the help, I know I can be frustrating lol.

EDIT: 3 torrents downloaded; first 3 with no script execution. I have to run out of the house so this is all I could do before I had to leave.