Last.fm scraper in development - help wanted
#1
Question 
http://forum.xbmc.org/showthread.php?tid=38378
spiff Wrote:i have considered it but i do not feel comfortable scraping a site that provides open api's. that being said, anyone else is ofc free to do it

Hi spiff!

I've already tried to begin with the last.fm scrapper. But i have some problems understanding how the flows and interaction between the scrapper and xbmc works...

I started modifying your allmusic scrapper. Just to have something to begin with..

I would like to fully understand i the flow.

First, the scrapper create the albumsearchurl, i maganaged to get that working... after a working url has been created xbmc makes the request to it and then the regexp to parse the resuts. What follows is what i don't fully understand, once i got the basic information, album title, and url.. how the request for the album information url is done. I never get a list of albums or anything.

This is mi getalbumsearchresult :
<GetAlbumSearchResults dest="8">
<RegExp input="$$5" output="&lt;results&gt;\1&lt;/results&gt;" dest="8">
<RegExp input="$$1" output="&lt;entity&gt;&lt;year&gt;2000&lt;/year&gt;&lt;genre&gt;test&lt;/genre&gt;&lt;title&gt;\2&lt;/title&gt;&lt;url&gt;http://www.last.fm/music\1&lt;/url&gt;&lt;/entity&gt;" dest="5">
<expression repeat="yes">&lt;a href=&quot;(.*)&quot;&gt;(.*)&lt;/a&gt; &lt;span</expression>
</RegExp>
<expression noclean="1"></expression>
</RegExp>
</GetAlbumSearchResults>

I don't know if all fields (year,genre,title,etc) need to exist in the result of the first request, i don't have them available at first, but i would from the url fetched in the regexp...

Perhaps there is something wrong with the regexp, ive tried m any simple ones, with no result, is there any way to force a valid result?. So i can get to the next step in the scrapper?.

Well, i don't really know if i'm actually making any sense here.. but thank you very much in advance for your help.

Pyro-X
Reply


Messages In This Thread
Last.fm scraper in development - help wanted - by pyro-x - 2008-10-13, 16:01
[No subject] - by spiff - 2008-10-13, 16:12
[No subject] - by pyro-x - 2008-10-14, 11:19
[No subject] - by v0lrath - 2008-10-14, 23:29
Tips! - by Gamester17 - 2008-10-15, 18:28
[No subject] - by DuMbGuM - 2008-11-18, 01:13
[No subject] - by spyrojyros_tail - 2008-11-21, 03:30
[No subject] - by rwparris2 - 2008-11-21, 05:30
[No subject] - by TechLife - 2008-11-22, 01:42
[No subject] - by spiff - 2008-11-22, 02:51
[No subject] - by TechLife - 2008-11-22, 02:55
[No subject] - by kriziz - 2008-12-07, 11:26
[No subject] - by Aron Parsons - 2008-12-24, 04:39
[No subject] - by kastrolis - 2008-12-29, 16:35
[No subject] - by Aron Parsons - 2008-12-29, 20:40
[No subject] - by spiff - 2008-12-30, 00:57
[No subject] - by kriziz - 2008-12-30, 12:33
[No subject] - by Aron Parsons - 2008-12-30, 17:24
[No subject] - by spiff - 2008-12-30, 18:32
[No subject] - by spiff - 2008-12-30, 22:38
[No subject] - by spiff - 2009-01-06, 19:42
[No subject] - by spiff - 2009-01-10, 15:41
[No subject] - by succo - 2009-01-10, 16:08
[No subject] - by spiff - 2009-01-10, 16:16
[No subject] - by succo - 2009-01-10, 16:19
[No subject] - by bashflyng - 2009-01-13, 01:02
[No subject] - by Loto_Bak - 2009-01-23, 04:08
[No subject] - by spiff - 2009-01-23, 16:38
[No subject] - by TheNME123 - 2009-02-17, 19:55
[No subject] - by Stranger - 2011-01-20, 20:31
[No subject] - by olympia - 2011-01-23, 18:10
[No subject] - by Stranger - 2011-01-25, 14:49
[No subject] - by olympia - 2011-01-25, 14:54
[No subject] - by Stranger - 2011-01-26, 01:25
[No subject] - by Zippolighter - 2011-02-28, 20:59
Logout Mark Read Team Forum Stats Members Help
Last.fm scraper in development - help wanted0