This forum has been archived. All content is frozen. Please use KDE Discuss instead.

[REQ] RSS Parser

Tags: None
(comma "," separated)
agforsyth
Registered Member
Posts
133
Karma
0

Thu Jun 08, 2006 3:22 am
lengau wrote:Separately, adding this would allow automatic control in KTorrent, which would make it a lot easier for other apps to download torrents, using KTorrent as a backend.


There are already three methods for loading torrents other than using the GUI, two useable by other programs.

The first is the "scanfolder" or autoload plugin. Any program could put a torrent in that folder, and ktorrent would load it and start the download.

The second is the openTorrentSilently DCOP call. Simply provide KTorrent with the location of the torrent to load, and it will start the download.

The third, not useable by other programs, is the new ktshell program I wrote. If you ssh into your box and want to load a torrent you can simply run ktshell and specify the location of the torrent, rather than having to use DCOP directly.
lengau
Registered Member
Posts
36
Karma
0

Thu Jun 08, 2006 6:01 am
Well then, there we go. I hadn't looked at or thought about any ways to do this when I wrote that (although I had used your script -- I should haev taken more thought before writing my comment), but the problem on the KTorrent side's already solved then. All we need is an aKregator add-on that allows us to make a DCOP call to KTorrent every time a torrent file is loaded with the feed. This seems like the easiest method (especially since there is no user setup needed).
Can KTorrent make a call back to aKregator (or whatever other program called it) to alert it that the torrent file has finished or will aKregator have to keep checking up on the torrents?
imported4-Ivan
Registered Member
Posts
819
Karma
0

Thu Jun 08, 2006 10:18 am
Can KTorrent make a call back to aKregator (or whatever other program called it) to alert it that the torrent file has finished or will aKregator have to keep checking up on the torrents?

I'm not sure that's doable via DCOP unless aKregator adds (or already has?) some DCOP method that's capable of doing this.
If there is such a method, I think it's possible to do something like this until we find the time to write RSS plugin.
lengau
Registered Member
Posts
36
Karma
0

Sun Jun 11, 2006 1:19 am
I was thinking that perhaps someone should implement that in aKregator rather than KTorrent. That way it would also be usable for other things, because whenever someone wants to add RSS functionality to their KDE program, they just make something that tells aKregator how to talk to it via DCOP (or in future DBUS).
imported4-Tomasu
Registered Member
Posts
302
Karma
0

Sun Jun 11, 2006 1:39 am
personally, I think it makes more sense to have a special purpose feed reader for ktorrent, so it can handle things the way it wants, instead of having to depend on another piece of software, that not everyone will be using, or even want to use.
lengau
Registered Member
Posts
36
Karma
0

Sun Jun 11, 2006 2:32 am
My thought was that the code would be reusable and that then there would only be one place to manage RSS feeds. I suppose another alternative is to have both. implementing our own RSS reading plugin shouldn't in any way interfere with DCOP, and if it's done as a plugin, it's optional. Those who want to use aKregator instead could, also.
imported4-Tomasu
Registered Member
Posts
302
Karma
0

Sun Jun 11, 2006 3:04 am
its not really a feature of akrigator to filter and grep feeds for links. to me, its something that would be fairly specialized and specific to an application like ktorrent.
lengau
Registered Member
Posts
36
Karma
0

Sun Jun 11, 2006 4:42 am
Well I disagree (anyway, as far as I can tell, aKregator would just need to send the article link to KTorrent), but let's agree to disagree.
I do agree, though, that it would be nice to be able to have a way to automatically add links from an RSS feed to KTorrent, but I feel that having a separate aggregator just for KTorrent is doing a bit too much.
George
Moderator
Posts
5421
Karma
1

Sun Jun 11, 2006 7:57 am
We haven't really thought about how to the RSS thing, but I don't want to rely on aKregator to signal KT of the torrents using DCOP calls.

I am hoping that the RSS related stuff is in a separate library we can use, and then provide a simple GUI for this, probably in a separate tab page like the search.

We add some way of filtering out unwanted torrents Maybe on season-episode basis, most of those torrents names will contain stuff like S2E15, 2x15 or something similar, we should be able to filter on that. (I don't think stuff like this is possible with aKregator, that's why I don't like to use it)
Belgabor
Registered Member
Posts
7
Karma
0

Sun Jun 18, 2006 2:15 am
There are specialized torrent RSS readers. One is tvrss.
George
Moderator
Posts
5421
Karma
1

Sun Jun 18, 2006 3:38 pm
Belgabor wrote:There are specialized torrent RSS readers. One is tvrss.


It's in PERL so of not much use for us.
imported4-Tomasu
Registered Member
Posts
302
Karma
0

Sun Jun 18, 2006 4:30 pm
I don't see how what language it is has anything to do with it. Perl can call dcop just fine :P as well as use the PerlKDE/PerlQt modules to talk to qt/kde directly.

Not to mention I know Qt3, Qt4, limited KDE Libs, and Perl, so if you wanted to make that script a base for the ktorrent plugin, I could get down to it... Though the ktorrent plugin api looks a little complex for just being plugins. And that I don't do autotools, I will NEVER do autotools.
Belgabor
Registered Member
Posts
7
Karma
0

Mon Jun 19, 2006 4:36 am
George wrote:
Belgabor wrote:There are specialized torrent RSS readers. One is tvrss.


It's in PERL so of not much use for us.


Sorry, I didn't mean to suggest to somehow include it in ktorrent, just that there are special programs that parse rss feeds and save the torrents to a dir (where ktorrent can auto-start them). My point was that I don't think ktorrent desperately needs a rss parser...
George
Moderator
Posts
5421
Karma
1

Mon Jun 19, 2006 4:56 pm
Belgabor wrote:
George wrote:
Belgabor wrote:There are specialized torrent RSS readers. One is tvrss.


It's in PERL so of not much use for us.


Sorry, I didn't mean to suggest to somehow include it in ktorrent, just that there are special programs that parse rss feeds and save the torrents to a dir (where ktorrent can auto-start them). My point was that I don't think ktorrent desperately needs a rss parser...


That's another option, but having a plugin in KT is more userfriendly.
btubbs
Registered Member
Posts
2
Karma
0

getmyshows.py

Mon Jul 31, 2006 11:08 pm
Belgabor wrote:There are specialized torrent RSS readers. One is tvrss.


I took a look at tvrss.sourceforge.net, but I didn't like it, mainly because it would mean using a bittorrent client that's even less mainstream than ktorrent.

That's why I wrote getmyshows.py, which uses cron jobs, ktorrent's scanfolder plugin, and tvrss.net search-based rss feeds to download new episodes of my favorite shows every day. (Don't confuse tvrss.net with tvrss.sourceforge.net. One is a source of feeds, the other is a feed reader.)

You can download getmyshows.py from http://tubbs.dyndns.org/files/getmyshows.py

You install it like this:
#1 - Create a text file at ~/shows, with one show name per line, formatted as it would be on http://tvrss.net/shows/ (e.g. "The Daily Show").
#2 - Create the directory ~/torrents.
#3 - Place getmyshows.py somewhere in your PATH, and make it executable.
#4 - Install the python feedparser module from http://feedparser.org, (or emerge dev-python/feedparser if you run gentoo).
#5 - Configure ktorrent's scanfolder plugin to watch the ~/torrents directory. It's also a good idea to check the boxes for "Open torrents silently" and "Move to 'loaded' directory after loading".
#6 - (Optional) Tweak the dstgrp, rlsgrp, quality, cutoffdays, showfile, or torrentdir variables if you know what you're doing. The defaults are probably best for most people.
#7 - Schedule a cron job to run this program at the same time every day. See http://www.scottahearn.com/links_crontab.php if you don't know how to do this.

I have run into one mysterious problem, though. Possibly a bug in the scanfolder plugin. Sometimes after my script runs, ktorrent will pop up an error saying that the torrent is corrupt. Yet if I move the same torrent back from the 'loaded' directory to the one being watched, ktorrent downloads it just fine.


Bookmarks



Who is online

Registered users: Bing [Bot], Evergrowing, Google [Bot]