xonglennao / transdroid

Automatically exported from code.google.com/p/transdroid
GNU General Public License v3.0
0 stars 0 forks source link

Add torrent to deluge 1.3 #145

Closed GoogleCodeExporter closed 8 years ago

GoogleCodeExporter commented 8 years ago
After upgrading my deluge install to 1.3rc1, I can't seem to add torrents from 
transdroid anymore. Based on the logs, the torrent file is being sent to the 
webserver, but the torrent is never added to the deluge session.

What steps will reproduce the problem?
Try to add a torrent from transdroid to the deluge daemon.

What version of the product are you using?
0.17.6

What torrent client are you using?
1.3RC1

Original issue reported on code.google.com by chase.sterling@gmail.com on 8 Jun 2010 at 2:51

GoogleCodeExporter commented 8 years ago
This is happening to me, too, but on Deluge 1.2.3 and Transdroid 0.18.1

Original comment by felix.og...@gmail.com on 11 Jun 2010 at 12:30

GoogleCodeExporter commented 8 years ago
Are you able to upload .torrent files to your server via Transdroid? Because I 
can. Indeed the problem seems to be in Deluge 1.3's handling of 'add by URL' in 
the web UI. Are you able to add torrents by URL using the Deluge web UI? 
Because I can't. I've asked for help from the Deluge developer(s?) here: 
http://forum.deluge-torrent.org/viewtopic.php?f=8&t=18675&p=137543#p137543

Original comment by erickok@gmail.com on 15 Jun 2010 at 11:08

GoogleCodeExporter commented 8 years ago
I can add torrents by URL using the Deluge WebUI on 1.2.3. I can't with 
Transdroid. I haven't tried uploading .torrent files using Transdroid, if I 
will, I'll let you know.

Original comment by felix.og...@gmail.com on 17 Jun 2010 at 3:17

GoogleCodeExporter commented 8 years ago
Deluge 1.2.3 works fine. Please update both you downloads and .torrent files 
folder locations to somewhere where deluge has write access.

Original comment by erickok@gmail.com on 21 Jun 2010 at 9:57

GoogleCodeExporter commented 8 years ago
I just upgraded to Transdroid 0.19.0 and this still doesn't work (it now gives 
a "torrent could not be added" error). Deluge does have write access to all the 
required folders. Also, the Web UI works without any problems (yes, including 
add torrent by URL). I attached the relevant bits of a logcat.

Looking at the logcat, I can spot a potential problem (which would indicate 
this is not related to Deluge at all). The "AddByUrl" task is reporting this 
URL:

http://btjunkie.org/torrent/PC-raquo-LEFT-4-DEAD-2-Full-Game-directplay-by-globe
/36495f7d63871a8345cc5d0809cd1071874dbc704fd1/download.torrent

However, if I go to the btjunkie.org site and download the same torrent, the 
URL is:

http://dl.btjunkie.org/torrent/PC-raquo-LEFT-4-DEAD-2-Full-Game-directplay-by-gl
obe/36495f7d63871a8345cc5d0809cd1071874dbc704fd1/download.torrent

(Notice the dl. subdomain) I'm not sure this is a problem, as the first URL 
(that Transdroid seems to use) does, in fact, download the correct torrent. 
Still, I thought it was worth mentioning.

Original comment by felix.og...@gmail.com on 23 Jun 2010 at 10:32

Attachments:

GoogleCodeExporter commented 8 years ago
What I need to judge what is happing is a log of deluged. This should spit out 
any errors of the requests that Transdroid sends to it. 

The fact that you can use the web UI's 'add by url' feature strangely does not 
mean it works for Transdroid as well. I can't tell you why, but it's something 
different. Anyway, the log of Deluge should tell what is going on.

Personally I would just kill any running Deluge instance and start 'deluged -d 
-L debug' from the command line. It will show the error messages right there.

Original comment by erickok@gmail.com on 23 Jun 2010 at 1:59

GoogleCodeExporter commented 8 years ago
Ok, here's some more info. First of all, 'deluged -d -L debug' wouldn't work, 
so I used 'deluge-web -L debug' which did work, and I think it's the right 
thing. I saved two relevant bits of debug -- when I tried to add a torrent with 
Transdroid and when I added one through the Web UI. I attached both. I hope 
this helps you in some way.

Original comment by felix.og...@gmail.com on 23 Jun 2010 at 8:48

Attachments:

GoogleCodeExporter commented 8 years ago
Right. What is happening is that Transdroid sends the request to Deluge and 
indeed it receives this correctly:

[DEBUG   ] 20:42:47 json_api:237 json-request: 
{"id":2,"method":"core.add_torrent_url","params":["http://btjunkie.org/torrent/U
buntu-9-10-i386-BETA/4358b74c45dccf021307145a899c1fbaf0d60663f899/download.torre
nt",[]]}

Now Deluge apparently downloads the download.torrent file, but when it want to 
open the .torrent file to read it, it fails to.

    file = open(self.fileName, 'wb')
    self.file = self.openFile(partialContent)
    failure.raiseException()

For some reason, very likely because of user rights, it cannot read the file 
again. Maybe the directory it saves the .torrent files into causes the newly 
downloaded download.torrent file to not have read permissions to group/other 
users?

Here is another user that experienced the same thing: 
http://forum.deluge-torrent.org/viewtopic.php?f=7&t=26825 If moving the 
location does not help, please ask your question again on the Deluge forum. As 
far as Transdroid is concerned all I can do is see if the request is send 
correctly to Trandroid (which it is) and hint at what is going on. I am really 
sorry it still doesn't work yet for you.

Original comment by erickok@gmail.com on 24 Jun 2010 at 11:27

GoogleCodeExporter commented 8 years ago
I tested today against the new Deluge 1.3 rc2 and the problem seems to be 
solved.

Original comment by erickok@gmail.com on 24 Aug 2010 at 8:14

GoogleCodeExporter commented 8 years ago
The release of Deluge 1.3 RC2 does fix the issue of not being able to add 
torrents via the web UI. I'm guessing that means it was an upstream bug from 
transdroid.

Original comment by z28...@gmail.com on 25 Aug 2010 at 11:08

GoogleCodeExporter commented 8 years ago
Also having this problem. I can write files to the download and torrent 
directories. Using 1.3.1 deluge and latest transdroid.
Any ideas or tips would be greatly appreciated.

Unhandled error in Deferred:
Traceback (most recent call last):
Failure: twisted.web.client.PartialDownloadError: 200 OK
[INFO    ] 12:18:30 core:239 Attempting to add url 
http://isohunt.com/download/91939749/Idiocracy.torrent
[ERROR   ] 12:18:33 core:253 Error occured downloading torrent from 
http://isohunt.com/download/91939749/Idiocracy.torrent
[ERROR   ] 12:18:33 core:254 Reason: 200 OK
[ERROR   ] 12:18:33 client:393 RPCError Message Received!
--------------------------------------------------------------------------------
RPCRequest: 
core.add_torrent_url(http://isohunt.com/download/91939749/Idiocracy.torrent, [])
--------------------------------------------------------------------------------
  File "/usr/local/lib/python2.6/dist-packages/deluge-1.3.1_dev-py2.6.egg/deluge/core/rpcserver.py", line 314, in on_fail
    failure.raiseException()
  File "/usr/lib/python2.6/dist-packages/twisted/python/failure.py", line 326, in raiseException
    raise self.type, self.value, self.tb

PartialDownloadError: 

Original comment by davesh...@gmail.com on 2 Nov 2010 at 4:21

GoogleCodeExporter commented 8 years ago
It seems that Deluge cannot download the requested torrent file. Have you tried 
different sites? It seems isohunt access has been restricted recently. Also, 
try to add the same url manually via the Deluge web interface to make sure the 
torrent actually works. 

Note that Transdroid sends the request just fine. 

Original comment by erickok@gmail.com on 3 Nov 2010 at 12:06

GoogleCodeExporter commented 8 years ago
Tried kickass, isohunt, btjunky, extratorrent, torrent reactor.
They all fail.

Torrent downloads and pirate bay do work though.

[INFO    ] 07:47:59 core:239 Attempting to add url 
http://www.kickasstorrents.com//torrents/idiocracy-limited-dvdrip-xvid-diamond-w
ww-torrentlounge-com-t3826244/
[ERROR   ] 07:47:59 core:253 Error occured downloading torrent from 
http://www.kickasstorrents.com//torrents/idiocracy-limited-dvdrip-xvid-diamond-w
ww-torrentlounge-com-t3826244/
[ERROR   ] 07:47:59 core:254 Reason: 302 Found to 
http://torcache.com/torrent/9F79D1309305A7F4612EEA526264858A5D95D7A4.torrent
[ERROR   ] 07:47:59 client:393 RPCError Message Received!
--------------------------------------------------------------------------------
RPCRequest: 
core.add_torrent_url(http://www.kickasstorrents.com//torrents/idiocracy-limited-
dvdrip-xvid-diamond-www-torrentlounge-com-t3826244/, [])
--------------------------------------------------------------------------------
  File "/usr/local/lib/python2.6/dist-packages/deluge-1.3.1_dev-py2.6.egg/deluge/core/rpcserver.py", line 314, in on_fail
    failure.raiseException()
  File "/usr/lib/python2.6/dist-packages/twisted/python/failure.py", line 326, in raiseException
    raise self.type, self.value, self.tb

PageRedirect:

Original comment by davesh...@gmail.com on 3 Nov 2010 at 11:54

GoogleCodeExporter commented 8 years ago
Forgot to mention that it also works file when adding torrents from an RSS feed 
such as tvtorrents.

Original comment by davesh...@gmail.com on 3 Nov 2010 at 12:39

GoogleCodeExporter commented 8 years ago
Clearly there is just something going on at those torrent sites. If this 
persists I will remove the sites from Transdroid. For now there is nothing 
Transdroid can do about it.

Original comment by erickok@gmail.com on 3 Nov 2010 at 7:56

GoogleCodeExporter commented 8 years ago
Is anybody else having these problems. Please test and report back. Curious to 
know if it's just me or not

Original comment by davesh...@gmail.com on 3 Nov 2010 at 9:16

GoogleCodeExporter commented 8 years ago
Really this has nothing to do with Deluge or even Transdroid, but here we go:

Tested on a 'wallpaper' search while connected to WiFi (in USA), connected to 
rTorrent at 10:00AM and selecting the first search result.

Working: BTJunkie, ExtraTorrent, Mininova, Monova, The Pirate Bay, Torrent 
Downloads
Not working: isoHunt (rTorrent incompatibility?), Kickass Torrents (server 
overload), Torrent Reactor (tacker down?), Vertor (tracker down?)

If having more persistent problems with a certain tracker, please open a new 
issue. Comments unrelated to Deluge 1.3's RC1 problem will be deleted here.

Original comment by erickok@gmail.com on 4 Nov 2010 at 2:06

GoogleCodeExporter commented 8 years ago
[deleted comment]
GoogleCodeExporter commented 8 years ago
[deleted comment]
GoogleCodeExporter commented 8 years ago
I have EXACTLY this issue!
TPB works, NO other site works. EZRSS works fine.

Original comment by yochai...@gmail.com on 22 Nov 2010 at 4:04

GoogleCodeExporter commented 8 years ago
It may be working with rtorrent but it fails with deluge. This is the problem 
we are having with transdroid. Below is the error I see in my logs. I can click 
on the link shown near the 302 error and it will download so the link is valid 
and not being changed. It's just not passing it correctly to deluge.

[DEBUG   ] 13:46:47 json_api:250 json-request: 
{"id":2,"method":"core.add_torrent_url","params":["http:\/\/btjunkie.org\/torren
t\/80-Dark-Wallpapers-Full-HD-1080p\/313045c30655f06da4b2cf7e78d154db6c2dd4e1d02
0\/download.torrent",[]]}
[INFO    ] 13:46:47 core:239 Attempting to add url 
http://btjunkie.org/torrent/80-Dark-Wallpapers-Full-HD-1080p/313045c30655f06da4b
2cf7e78d154db6c2dd4e1d020/download.torrent
[ERROR   ] 13:46:47 core:253 Error occured downloading torrent from 
http://btjunkie.org/torrent/80-Dark-Wallpapers-Full-HD-1080p/313045c30655f06da4b
2cf7e78d154db6c2dd4e1d020/download.torrent
[ERROR   ] 13:46:47 core:254 Reason: 302 Found to 
http://dl.btjunkie.org/torrent/80-Dark-Wallpapers-Full-HD-1080p/313045c30655f06d
a4b2cf7e78d154db6c2dd4e1d020/download.torrent
[ERROR   ] 13:46:47 client:393 RPCError Message Received!
--------------------------------------------------------------------------------
RPCRequest: 
core.add_torrent_url(http://btjunkie.org/torrent/80-Dark-Wallpapers-Full-HD-1080
p/313045c30655f06da4b2cf7e78d154db6c2dd4e1d020/download.torrent, [])
--------------------------------------------------------------------------------
  File "/usr/lib/pymodules/python2.6/deluge/core/rpcserver.py", line 314, in on_fail
    failure.raiseException()
  File "/usr/lib/python2.6/dist-packages/twisted/python/failure.py", line 326, in raiseException
    raise self.type, self.value, self.tb

PageRedirect: 
--------------------------------------------------------------------------------

Original comment by davesh...@gmail.com on 25 Nov 2010 at 6:49

GoogleCodeExporter commented 8 years ago
Just noticed that if I run wget 
http://btjunkie.org/torrent/80-Dark-Wallpapers-Full-HD-1080p/313045c30655f06da4b
2cf7e78d154db6c2dd4e1d020/download.torrent it works but if I open it in a 
browser it does not. These sites for other Transdroid users though so it must 
be the method that it is sending the link to deluge. If it was the site it 
wouldn't be working for anybody.

Original comment by davesh...@gmail.com on 25 Nov 2010 at 6:52

GoogleCodeExporter commented 8 years ago
That link points to an HTML page, not to a .torrent file (even though the 
.torrent at the end of the URL might indicate that). Click it in your browser 
and you;ll see. That why wget works (it gets the HTML file). I think BTJunkie 
does a redirect to the HTML file if one tries to download the .torrent directly 
without going through their site. Probably an advertisement thing.

I'm sorry to tell you again but I cannot stand for anything individual sites or 
torrent clients do. As far as Transdroid goes it only send the link to the 
torrent client; a link that the site gives me. Even within a single site some 
torrents may or may not work but I am dependent on the merits of those sites 
and there compatibility with torrent clients.

Original comment by erickok@gmail.com on 29 Nov 2010 at 10:39