xbenjii / torrentexpander

Automatically exported from code.google.com/p/torrentexpander
0 stars 0 forks source link

rTorrent & Advanced scripting bug #53

Closed GoogleCodeExporter closed 8 years ago

GoogleCodeExporter commented 8 years ago
What steps will reproduce the problem?
1. Use torrentexpander to run a script that work for some time
2. rTorrent will stop working until the script ends.

What do you see?
Absolutely no response from rtorrent (it's freezed) while my scripts run.

Original issue reported on code.google.com by login...@gmail.com on 21 Jan 2012 at 3:35

GoogleCodeExporter commented 8 years ago
This is not a torrentexpander issue but a rtorrent limitation

torrentexpander is probably freezing rtorrent too

Can you try to launch torrentexpander with a line like this one (it should 
allow it to multitask):
system.method.set_key = event.download.finished,torrentexpander,"execute=. 
/path/to/your/torrentexpander.sh,$d.get_base_path=,$d.get_base_filename="
Instead of :
system.method.set_key = 
event.download.finished,torrentexpander,"execute=/path/to/your/torrentexpander.s
h,$d.get_base_path=,$d.get_base_filename="

Let me know how it works for you

Thanks

Original comment by addicted...@gmail.com on 21 Jan 2012 at 5:58

GoogleCodeExporter commented 8 years ago
That won't work on so many levels, starting with the fact the command provided 
to execute is NOT passed to a shell (so '.' is not 'source'), since execvp() is 
used.

What works is using execute.bg= in 0.8.9, which will leave zombies behind 
though due to a buggy implementation. Or you decouple your script yourself from 
the calling process (i.e. demonize it), which is the best way.

Original comment by pyroscope.project on 21 Jan 2012 at 9:33

GoogleCodeExporter commented 8 years ago
Hi
I'm sorry but you lost me from the first line of your comment.
I'll need to do some research, as I'm not familiar with any of these.

I'm getting worried because I use the . to restart torrentexpander after an 
update. It seems to work, but can it cause an issue, or is this restricted to 
rtorrent.
Remember that I'm still a n00b that discovered shell programming while starting 
this project.

Thanks

Original comment by addicted...@gmail.com on 21 Jan 2012 at 11:18

GoogleCodeExporter commented 8 years ago
Pyroscope!, welcome to torrentexpander.
I'm using rtorrent 0.8.6, i will try to update to use your suggestion!

Original comment by login...@gmail.com on 22 Jan 2012 at 12:27

GoogleCodeExporter commented 8 years ago
Google's your friend, in this case using "bash daemonize".

If you properly decouple a script from rTorrent, you can even send xmlrpc 
commands back to it, which would otherwise result in a deadlock.

Original comment by pyroscope.project on 22 Jan 2012 at 11:14

GoogleCodeExporter commented 8 years ago
I will try with nohup

Original comment by login...@gmail.com on 22 Jan 2012 at 6:20

GoogleCodeExporter commented 8 years ago
rTorrent defect

Original comment by login...@gmail.com on 25 Jan 2012 at 6:13