[REQ]Removing extraneous output from IMDb script

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
GnomesRUs
Posts: 41
Joined: 2005-08-30 18:10:10
Location: U.S.A.

[REQ]Removing extraneous output from IMDb script

Post by GnomesRUs »

I have just recently begun adding movies to my AMC again after a couple of years' hiatus, and am finding a lot of 'junk' in the comments section, specifically appended to the Trivia. For example:

At the end of each trivia line text similar to this appears:
42 of 43 found this interestingInteresting?YesNo|

Then on many entries, at the end of the Trivia there's a Javascript segment of varying length and content (sometimes quite HUGE!), like this:
if ('csm' in window) {csm.measure('csm_TitleContributeWidget_started');}Getting Started|Contributor Zone »Contribute to This PageEdit pageif ('csm' in window) {csm.measure('csm_TitleContributeWidget_finished');}

It's not so bad if there are only a few lines to edit, but I just did "Artificial Intelligence A.I.", and there were 52 lines of Trivia to edit, and I'm sure there are films with even more lines of Trivia. This will also make for a great increase in the size of my catalog, uless I completely turn off the downloading of the Trivia, which I'd rather not do...

Any script guru's out there that can help, maybe?
antp
Site Admin
Posts: 9629
Joined: 2002-05-30 10:13:07
Location: Brussels
Contact:

Post by antp »

Do you mean that the current script (v3.85) imports that by mistake in the comment? Or that in your previously imported movie there were that junk imported by the script back then?
In the first case it is rather the IMDb script that should be fixed.
GnomesRUs
Posts: 41
Joined: 2005-08-30 18:10:10
Location: U.S.A.

Post by GnomesRUs »

I've only seen the 42 of 43 found this interestingInteresting?YesNo| added at the end of each line after 2014-12-15, but the Javascript has been appearing for a couple of years, now.
antp
Site Admin
Posts: 9629
Joined: 2002-05-30 10:13:07
Location: Brussels
Contact:

Post by antp »

If you can give a few movie URLs with this problem, and which options you enabled about what to import, I can check if I can easily fix that problem in the current script.
Cleaning the comments is maybe not very easy to do if there isn't a clearly defined structure, but if the script is fixed you can always re-import comments on those which have bad ones.
humungus
Posts: 24
Joined: 2010-03-23 00:29:01

Post by humungus »

antp wrote:Do you mean that the current script (v3.85)
Be aware that the current script is actually version 3.86, but I think it's only available inside elman's topic. Over the past few weeks I used it to update 900+ movies and none of them had issues mentioned by GnomesRUs. I also tried Artificial Intelligence: AI just now, and no problems here either. The only "problems" are with categories like Cameo, Director Cameo or Director Trademark, but they're a very minor gripe.
GnomesRUs
Posts: 41
Joined: 2005-08-30 18:10:10
Location: U.S.A.

Post by GnomesRUs »

elman's updated script seems to do the trick and eliminates the Interesting?YesNo| mess at the end of the Trivia lines (Thank You, Sir! :) )

For some strange, unknown reason, though, I ended up having to reinstall AMC after replacing the old IMDB.ifs with this new one - AMC would no longer see the script until I did...

The application just keeps getting better and better - Thank You to all involved :)
antp
Site Admin
Posts: 9629
Joined: 2002-05-30 10:13:07
Location: Brussels
Contact:

Post by antp »

humungus wrote: Be aware that the current script is actually version 3.86, but I think it's only available inside elman's topic.
Thanks! Indeed he modified it several times, it seems I missed the last update.
Post Reply