[REQ] Problems with IMDB 3.80

If you made a script you can offer it to the others here, or ask help to improve it. You can also report here bugs & problems with existing scripts.
Post Reply
chalket
Posts: 8
Joined: 2013-10-18 16:33:20

[REQ] Problems with IMDB 3.80

Post by chalket »

Hi,
I've been using AMC for several years now, but this is my first posting in the forum. The IMDB script is the only one I use, it has had a variety of quirks over the years but overall I have been very pleased. Thanks!

My current problem is that the script seems to be accessing IMDB's "Combined" page instead of the "Main" page that it used to use. Because of that (I assume), it no longer finds a "Description" for the movie, quite a major flaw! (I can't believe I am the only one finding this?) It does still import the tag-line into the Description field, but it no longer imports any kind of Description (or the Awards anymore, either). No description makes the program pretty much useless to me.

On a side note, it has been several updates since the "Comments" import has worked properly. If I use CommentType=0 (Standard, Only one comment from main page) it works, but the CommentType=1 (Detailed, 10 most useful comments) that I used to use (the one I prefer) hasn't worked since July 2011.

I have many new movies to catalog, so I really hope this can be addressed soon. Thanks!

*EDIT*
Am I really the only one having this problem? Or am I the only one using the IMDB script?? Either way, I really need some help with this... does anyone know how I could contact any of the writers of the script?
cage
Posts: 7
Joined: 2010-10-08 17:15:42

Post by cage »

The IMDB script will continually break; there is no way around this. You'll need to modify the IMDB.ifs file if nobody is there to do it for you.

Comment out line 390

Code: Select all

Value := StringReplace(Value, '<div class="info-content">', '');
and replace it with the following:

Code: Select all

Value := TextBetween(Value, '<div class="info-content">', '<a class="tn15more inline"');
This is just a quick and dirty hack to get the descriptions working again. Do not be surprised if IMDB makes changes that break this.
antp
Site Admin
Posts: 9630
Joined: 2002-05-30 10:13:07
Location: Brussels
Contact:

Post by antp »

With which movie have you tested this? It does not seem to change anything :??:
chalket
Posts: 8
Joined: 2013-10-18 16:33:20

Post by chalket »

To antp: I tried the suggested change and it seems to work for me. (I tested it on "Leaving Las Vegas" and it did grab the description.)

To cage: Thanks very much for your help, I have absolutely zero programming knowledge so I would *never* have gotten there on my own! My troubles with this script are far from solved, but at least you have returned the basic functionality for me. Thanks again!

To all: I don't want to sound ungrateful, but how hard would it be to return the "Award" function (import to description field)?
cage
Posts: 7
Joined: 2010-10-08 17:15:42

Post by cage »

I noticed I had some issues scraping descriptions that were long ie. had a link to 'see full summary'

The original changes worked well when scraping descriptions with short descriptions that didn't flow into the 'full summary' page.

The following will grab the full description; you can disregard the previous changes...

comment out 894

Code: Select all

Value := TextBefore(Value, '<i>', '');
comment out 890

Code: Select all

Value := TextBetween(PageText, '<p class="plotpar">', '</p>');
replace with

Code: Select all

Value := TextBetween(PageText, '<p class="plotSummary">', '</p>');
comment out 904

Code: Select all

Value := TextBetween(PageText, '<p class="plotpar">', '</p>');
replace with

Code: Select all

Value := TextBetween(PageText, '<p class="plotSummary">', '</p>');

Sample long description : http://www.imdb.com/title/tt0097550/
Sample short description: http://www.imdb.com/title/tt0087759/

This is working fine for me.

EDIT
Fixed up the multi comments bug
Fixed awards scraping

I don't use either of those 2 options. This script needs a major rewrite as it's a total mess.

I'm just keeping my updates here:

http://bit.ly/NhjwGf
Last edited by cage on 2014-03-01 22:15:44, edited 4 times in total.
chalket
Posts: 8
Joined: 2013-10-18 16:33:20

Post by chalket »

All I can say is "Wow! Good job!":grinking: It was impressive enough getting the description fixed, but now you've got the multi-comment import working again for the first time in more than 2 years? Dude, you're awesome!

Now, if you could just get the Award import working again, you would be a god! ;)
antp
Site Admin
Posts: 9630
Joined: 2002-05-30 10:13:07
Location: Brussels
Contact:

Post by antp »

Thanks for the full file, I'll put that one as official version 3.81 then
chalket
Posts: 8
Joined: 2013-10-18 16:33:20

Post by chalket »

Now, if you could just get the Award import working again, you would be a god! wink
Come on, cage, don't quit now! You have this script soooo close to perfect again! Why not fix the Award import function and finish the job in style? Then it could *really* be the "official version 3.81" with your name credited! :clapping:
antp
Site Admin
Posts: 9630
Joined: 2002-05-30 10:13:07
Location: Brussels
Contact:

Post by antp »

Well his version is already 3.81 with his name credited :??:
Next fix would become 3.82 then
chalket
Posts: 8
Joined: 2013-10-18 16:33:20

Post by chalket »

Aw, come on, antp! You're not helping me cajole him (or her?) into finishing the job! :hum:
cage
Posts: 7
Joined: 2010-10-08 17:15:42

Post by cage »

This script was updated to 3.82 awhile back. Looks like http://update.antp.be/amc/scripts/ is still on 3.81.
antp
Site Admin
Posts: 9630
Joined: 2002-05-30 10:13:07
Location: Brussels
Contact:

Post by antp »

Thanks. I'll update it.
Post Reply