Opened 14 years ago

Closed 14 years ago

#395 closed patch (fixed)

Fix for imdb.pl script not picking up Genres for a movie without keywords

Reported by: harywilke@… Owned by: jdonavan
Priority: minor Milestone: unknown
Component: mythvideo Version: head
Severity: low Keywords: imdb
Cc: Ticket locked: no

Description

I was poking around in this script when i saw that it would miss Genres for any movie that didn't have a "(More)" link to keywords at the end of the Genre list. For example: http://imdb.com/title/tt0390463/ would not return any Genres. The fix entails simply changing the end criteria from the "(More)" link to "User Comments" Class. Looking around at other movies, I think that this is the safest point to end the seach area for Genres. I thuoght about using Tagline wich is generaly right below Genres, but not all movies had one, also some movies had a Plot Summery while others had a Plot Outline so neither of those would work.

I'm no perl expert by any stretch so please double-check this. i tried it out on about 20 differnt movies and it gave the desired return so i'm pretty sure that it's a good fix.

Attachments (2)

imdb.pl-GenreFix.diff (611 bytes) - added by harywilke@… 14 years ago.
imdb.pl-GenreFix.02.diff.txt (612 bytes) - added by harywilke@… 14 years ago.

Download all attachments as: .zip

Change History (7)

Changed 14 years ago by harywilke@…

Attachment: imdb.pl-GenreFix.diff added

comment:1 Changed 14 years ago by danielk

Owner: changed from Isaac Richards to xris

Chris, can you have a look at this?

perl is a foreign language to me.

comment:2 Changed 14 years ago by xris

Owner: changed from xris to jdonavan

comment:3 Changed 14 years ago by chrissh72@…

another 2 examplaes of imdb entries that fail.

http://www.imdb.com/title/tt0401815/ http://www.imdb.com/title/tt0416315/

the suggested patch doesn't work for me, it breaks the script. Ik you need the exact error msg please ask.

Chris

comment:4 Changed 14 years ago by harywilke@…

oops. sorry about that. I just forgot to escape out the quotes. Perl is defiantly not my native tongue. I'm upping a revised patch that should work.

Changed 14 years ago by harywilke@…

comment:5 Changed 14 years ago by Isaac Richards

Resolution: fixed
Status: newclosed

(In [8543]) Fix #395 (patch to fix parsing of genre from imdb).

Note: See TracTickets for help on using tickets.